bundles/users: remove duplicate keys from ssh pubkeys
This commit is contained in:
parent
36219dbb95
commit
4666f1c923
1 changed files with 1 additions and 1 deletions
|
@ -45,7 +45,7 @@ for username, attrs in node.metadata['users'].items():
|
||||||
|
|
||||||
if 'ssh_pubkey' in attrs:
|
if 'ssh_pubkey' in attrs:
|
||||||
files[home + '/.ssh/authorized_keys'] = {
|
files[home + '/.ssh/authorized_keys'] = {
|
||||||
'content': '\n'.join(sorted(attrs['ssh_pubkey'])) + '\n',
|
'content': '\n'.join(sorted(set(attrs['ssh_pubkey']))) + '\n',
|
||||||
'owner': username,
|
'owner': username,
|
||||||
'mode': '0600',
|
'mode': '0600',
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue