refactor: consolidate all roles into ansible/roles/ and update ansible.cfg

- Move all roles from playbooks/roles/ to roles/
- Update roles_path in ansible.cfg
- Add cast user to common role
- Create standalone podman role
- Add semaphore role with Podman + Quadlet support
This commit is contained in:
Hermes Agent service account
2026-05-26 22:22:08 -05:00
parent 9250b0f193
commit 92b2a9d609
98 changed files with 158 additions and 78 deletions

View File

@@ -0,0 +1,30 @@
---
- name: Create jarvis group
ansible.builtin.group:
name: "{{ jarvis_group }}"
state: present
system: false
- name: Create jarvis user
ansible.builtin.user:
name: "{{ jarvis_user }}"
group: "{{ jarvis_group }}"
shell: "{{ jarvis_shell }}"
create_home: true
state: present
- name: Deploy SSH public key
ansible.posix.authorized_key:
user: "{{ jarvis_user }}"
key: "{{ lookup('file', '~/.ssh/id_jarvis.pub') }}"
state: present
exclusive: true
- name: Grant passwordless sudo
ansible.builtin.copy:
dest: "/etc/sudoers.d/{{ jarvis_user }}"
content: "{{ jarvis_user }} ALL=(ALL) NOPASSWD:ALL\n"
owner: root
group: root
mode: '0440'
when: jarvis_sudo_nopasswd | bool