Minor cleanup.
authorLuke Hoersten <luke@hoersten.org>
Thu, 18 Jan 2024 16:04:11 -0600
changeset 225 6936497313ac
parent 224 25e44d8440d4
child 226 ce33bf94045f
Minor cleanup.
rpi-base/tasks/main.yaml
--- a/rpi-base/tasks/main.yaml	Tue Jan 16 00:04:53 2024 -0600
+++ b/rpi-base/tasks/main.yaml	Thu Jan 18 16:04:11 2024 -0600
@@ -61,13 +61,12 @@
     shell: "/bin/bash"
     append: yes
 
-- name: authorize admin ssh keys
-  become: yes
-  authorized_key: user="{{admin_user_name}}" key="https://github.com/{{github_user}}.keys"
-
 - name: authorize ssh keys
   become: yes
-  authorized_key: user="{{ansible_user}}" key="https://github.com/{{github_user}}.keys"
+  authorized_key: user="{{item}}" key="https://github.com/{{github_user}}.keys"
+  loop:
+    - "{{admin_user_name}}"
+    - "{{ansible_user}}"
 
 - name: nopasswd sudo for admin user
   become: yes