diff --git a/update_immich.yml b/update_immich.yml index 5339a25..8f8efba 100644 --- a/update_immich.yml +++ b/update_immich.yml @@ -57,6 +57,28 @@ state: present update_cache: yes + + - name: Immich | Check compose directory exists on VM + ansible.builtin.command: + argv: + - sshpass + - -e + - ssh + - -o + - StrictHostKeyChecking=no + - -o + - ConnectTimeout=15 + - "{{ vm_user }}@{{ vm_ip }}" + - bash + - -lc + - "test -d {{ immich_compose_dir }}" + environment: + SSHPASS: "{{ vm_pass }}" + register: immich_dir + changed_when: false + failed_when: immich_dir.rc != 0 + + - name: Run Immich update commands on VM (via SSH) # use SSHPASS env, hide item value ansible.builtin.command: argv: