Signed-off-by: Marc Ahlgrim <marc@onemarcfifty.com>
This commit is contained in:
Marc Ahlgrim
2022-09-18 15:37:32 +02:00
parent 47d56593ed
commit 160bc51832
2 changed files with 15 additions and 3 deletions
+4 -1
View File
@@ -53,9 +53,12 @@
dest: "/etc/sudoers.d/ansiblessh"
content: "ansiblessh ALL=(ALL) NOPASSWD: ALL"
# now we deploy the ssh key. For this we just copy the id_rsa.pub file
# to the host
- name: Deploy SSH Key
authorized_key: user=ansiblessh
key="{{ lookup('id_rsa', '/var/lib/rundeck/.ssh') }}"
key="{{ lookup('file', '/var/lib/rundeck/.ssh/id_rsa.pub') }}"
state=present