You've already forked linux_ws2122_ansible
Initial Commit
This commit is contained in:
16
roles/unix_users/templates/authorized_keys.j2
Normal file
16
roles/unix_users/templates/authorized_keys.j2
Normal file
@ -0,0 +1,16 @@
|
||||
#jinja2: lstrip_blocks: True
|
||||
{% set keys = [item.value.ssh_key] %}
|
||||
{% if item.value.additional_ssh_keys is defined %}
|
||||
{% for key in item.value.additional_ssh_keys %}
|
||||
{% if inventory_hostname in key.hosts or 'all' in key.hosts %}
|
||||
{{- keys.append(key.name) -}}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
{% for key in keys %}
|
||||
{% if unix_users_ssh_options is defined %}
|
||||
{{ lookup('file', 'pubkeys/' + key) | regex_replace('(.*\S.*)', unix_users_ssh_options + ' \\1') }}
|
||||
{% else %}
|
||||
{{ lookup('file', 'pubkeys/' + key) }}
|
||||
{% endif %}
|
||||
{% endfor %}
|
1
roles/unix_users/templates/forward.j2
Normal file
1
roles/unix_users/templates/forward.j2
Normal file
@ -0,0 +1 @@
|
||||
{{ item.value.email }}
|
Reference in New Issue
Block a user