bundles/users: also deploy shell config

This commit is contained in:
Franzi 2020-03-27 13:33:37 +00:00
parent 6656a0864f
commit 841b49cd18
Signed by: kunsi
GPG key ID: 12E3D2136B818350
3 changed files with 63 additions and 0 deletions

View file

@ -14,6 +14,11 @@ users['root'] = {
'password': repo.vault.human_password_for('root on {}'.format(node.name)),
}
files['/etc/bash.bashrc'] = {
'source': 'bashrc',
'content_type': 'mako',
}
for username, attrs in node.metadata['users'].items():
home = attrs.get('home', '/home/{}'.format(username))
@ -46,3 +51,12 @@ for username, attrs in node.metadata['users'].items():
else:
files[home + '/.ssh/authorized_keys'] = {'delete': True}
files[home + '/.config/fish/config.fish'] = {
'content_type': 'mako',
}
for user, config in users.items():
files[config['home'] + '/.bashrc'] = {
'delete': True,
}