Hey folks, Ansible is messing me around. I've got a load of nested defaults that are setup in <role>/defaults/main.yml
as follows:
aaa:
accounts:
min_uid: 1000
max_uid: 60000
min_system_uid: 500
max_system_uid: 999
encryption_method: SHA512
console:
consoles: '/etc/console'
su_path: 'PATH=/usr/local/sbin:/usr/local/bin:/usr/bin'
env_path: 'PATH=/usr/local/sbin:/usr/local/bin:/usr/bin'
tty_group: tty
tty_perm: 0600
erase_character: 0117
kill_character: 025
umask: 0027
motd_path: '/etc/motd'
and I'm using them in a template like this:
## Login Defaults
#### Account-related Settings
UID_MIN {{ aaa.accounts.min_uid }}
UID_MAX {{ aaa.accounts.max_uid }}
SYS_UID_MIN {{ aaa.accounts.min_system_uid }}
SYS_UID_MAX {{ aaa.accounts.max_system_uid }}
ENCRYPT_METHOD {{ aaa.accounts.encryption_method }}
#### Console-related Settings
CONSOLE {{ aaa.console.consoles }}
ENV_SUPATH {{ aaa.console.su_path }}
ENV_PATH {{ aaa.console.env_path }}
TTYGROUP {{ aaa.console.tty_group }}
TTYPERM {{ aaa.console.tty_perm }}
ERASECHAR {{ aaa.console.erase_character }}
KILLCHAR {{ aaa.console.kill_character }}
UMASK {{ aaa.console.umask }}
MOTD_FILE {{ aaa.console.motd_path }}
but the numbers are rendering differently:
#### Account-related Settings
UID_MIN 1000
UID_MAX 60000
SYS_UID_MIN 500
SYS_UID_MAX 999
ENCRYPT_METHOD SHA512
#### Console-related Settings
CONSOLE /etc/console
ENV_SUPATH PATH=/usr/local/sbin:/usr/local/bin:/usr/bin
ENV_PATH PATH=/usr/local/sbin:/usr/local/bin:/usr/bin
TTYGROUP tty
TTYPERM 384 # this is not the number I was expecting
ERASECHAR 79 # neither is this
KILLCHAR 21 # nor this
UMASK 23 # or this...
MOTD_FILE /etc/motd
Weirdly, it's not all the numbers, just some of them, has anyone seen this before?