jmri: add rblundon@laptop SSH key for xpra access
Adds jmri_ssh_authorized_keys_extra list to support multiple authorized keys on the jmri account. Deploys rblundon's MacBook key so xpra can connect via SSH without a password.
This commit is contained in:
@@ -6,3 +6,5 @@ jmri_lcrr_branch: "clean-profile"
|
||||
jmri_leviton_email: "{{ leviton_email }}"
|
||||
jmri_leviton_password: "{{ leviton_password }}"
|
||||
jmri_ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINnSM/9fO8rz/amqkyoGUzUKNNzzmtSXPwOCr1O9zKNO ansible"
|
||||
jmri_ssh_authorized_keys_extra:
|
||||
- "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIG6HaK4Y21UwPRbAZ986L7I9QnUdyq53114+9kO8X4bL rblundon@laptop"
|
||||
|
||||
@@ -22,6 +22,7 @@ jmri_lcrr_branch: "main"
|
||||
|
||||
# SSH key for jmri user (for jmri-gui X11 access — set per-host in host_vars)
|
||||
jmri_ssh_authorized_key: ""
|
||||
jmri_ssh_authorized_keys_extra: [] # additional keys (e.g. operator laptops)
|
||||
|
||||
# SSH key for jmri user → Gitea
|
||||
jmri_gitea_key: /home/jmri/.ssh/id_ed25519_gitea
|
||||
|
||||
@@ -30,6 +30,13 @@
|
||||
state: present
|
||||
when: jmri_ssh_authorized_key | length > 0
|
||||
|
||||
- name: Deploy extra SSH authorized keys for jmri user
|
||||
ansible.posix.authorized_key:
|
||||
user: "{{ jmri_user }}"
|
||||
key: "{{ item }}"
|
||||
state: present
|
||||
loop: "{{ jmri_ssh_authorized_keys_extra }}"
|
||||
|
||||
- name: Add JMRI user to dialout group (serial device access)
|
||||
ansible.builtin.user:
|
||||
name: "{{ jmri_user }}"
|
||||
|
||||
Reference in New Issue
Block a user