summaryrefslogtreecommitdiff
path: root/roles/whawty/auth/store/tasks
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2024-01-24 15:09:06 +0100
committerChristian Pointner <equinox@spreadspace.org>2024-01-24 15:09:06 +0100
commitfa8ab1026ee131ab8d68808bd7ebab3c5657f5bb (patch)
tree3ec18c95b8d946fdfd36a48a30e0c6050898f000 /roles/whawty/auth/store/tasks
parentwhawty/auth/store role mostly done (diff)
whawty/auth/store: fix permission handling and add know-hosts file
Diffstat (limited to 'roles/whawty/auth/store/tasks')
-rw-r--r--roles/whawty/auth/store/tasks/sync-client.yml5
1 files changed, 4 insertions, 1 deletions
diff --git a/roles/whawty/auth/store/tasks/sync-client.yml b/roles/whawty/auth/store/tasks/sync-client.yml
index 106e347b..92657312 100644
--- a/roles/whawty/auth/store/tasks/sync-client.yml
+++ b/roles/whawty/auth/store/tasks/sync-client.yml
@@ -24,7 +24,10 @@
type: ed25519
comment: "whawty-auth-sync-{{ whawty_auth_store.name }}@{{ inventory_hostname }}"
-## TODO: known-hosts file...
+- name: generate known_hosts file
+ shell: "ssh-keyscan{% if 'port' in whawty_auth_store.sync %} -p {{ whawty_auth_store.sync.port }}{% endif %} {{ whawty_auth_store.sync.hostname }} > /etc/whawty/auth/.store-{{ whawty_auth_store.name }}-sync/known_hosts"
+ args:
+ creates: "/etc/whawty/auth/.store-{{ whawty_auth_store.name }}-sync/known_hosts"
- name: install systemd units for whawty-auth store sync client
loop: