deploy-homarr: rootless — drop become, reset_connection for docker group, all creds from Infisical
This commit is contained in:
parent
cabb9c1db8
commit
ab113d4174
@ -68,10 +68,9 @@
|
||||
ansible.builtin.debug:
|
||||
msg: "Homarr secret retrieved + valid. Proceeding to deploy."
|
||||
|
||||
- name: "Deploy Homarr (as ansible user)"
|
||||
- name: "Deploy Homarr (rootless, as ansible user)"
|
||||
hosts: "{{ target | default('racknerd1') }}"
|
||||
gather_facts: true
|
||||
become: true
|
||||
gather_facts: false
|
||||
vars:
|
||||
deploy_user: ansible
|
||||
homarr_dir: "/home/{{ deploy_user }}/docker/homarr"
|
||||
@ -83,7 +82,13 @@
|
||||
ansible_ssh_private_key_file: "/tmp/homarr_deploy_key"
|
||||
ansible_ssh_common_args: "-o StrictHostKeyChecking=accept-new -o IdentitiesOnly=yes"
|
||||
tasks:
|
||||
- name: Docker available?
|
||||
- name: Reset connection so docker group membership is active in this session
|
||||
ansible.builtin.meta: reset_connection
|
||||
|
||||
- name: Gather facts (after connection reset)
|
||||
ansible.builtin.setup:
|
||||
|
||||
- name: Docker available (rootless, via docker group)?
|
||||
ansible.builtin.command: docker version
|
||||
register: dv
|
||||
changed_when: false
|
||||
|
||||
Loading…
Reference in New Issue
Block a user