|
@ -167,11 +167,6 @@ |
|
|
path: "/etc/ssh/user_ca.pub" |
|
|
path: "/etc/ssh/user_ca.pub" |
|
|
text: "ssh-rsa {{ user_ca_key }}" |
|
|
text: "ssh-rsa {{ user_ca_key }}" |
|
|
|
|
|
|
|
|
- name: update container user ca key |
|
|
|
|
|
shell: lxc-attach -n {{ vm_name }} --clear-env -e -- bash -c "grep -F 'ssh-rsa {{ user_ca_key }}' /etc/ssh/user_ca.pub || echo 'ssh-rsa {{ user_ca_key }}' > /etc/ssh/user_ca.pub" |
|
|
|
|
|
register: update_user_ca_key |
|
|
|
|
|
changed_when: "update_user_ca_key.stdout != 'ssh-rsa {{ user_ca_key }}'" |
|
|
|
|
|
|
|
|
|
|
|
- name: trust user ca key |
|
|
- name: trust user ca key |
|
|
shell: lxc-attach -n {{ vm_name }} --clear-env -e -- bash -c "grep -F 'TrustedUserCAKeys /etc/ssh/user_ca.pub' /etc/ssh/sshd_config || echo 'TrustedUserCAKeys /etc/ssh/user_ca.pub' >> /etc/ssh/sshd_config" |
|
|
shell: lxc-attach -n {{ vm_name }} --clear-env -e -- bash -c "grep -F 'TrustedUserCAKeys /etc/ssh/user_ca.pub' /etc/ssh/sshd_config || echo 'TrustedUserCAKeys /etc/ssh/user_ca.pub' >> /etc/ssh/sshd_config" |
|
|
register: trust_ca_key |
|
|
register: trust_ca_key |
|
|