changed backup procedure

This commit is contained in:
Kevin Veen-Birkenbach 2023-12-24 22:50:00 +01:00
parent 647206b803
commit c2fe8a95c0

View File

@ -9,12 +9,23 @@
removes: "{{ docker_compose_file_path }}" removes: "{{ docker_compose_file_path }}"
become: true become: true
- name: register directory
stat:
path: "{{docker_compose_instance_directory}}"
register: docker_compose_instance_directory_register
- name: checkout repository
ansible.builtin.shell: git checkout .
become: true
args:
chdir: "{{docker_compose_instance_directory}}"
when: docker_compose_instance_directory_register.stat.exists
- name: pull docker repository - name: pull docker repository
git: git:
repo: "https://github.com/opf/openproject-deploy" repo: "https://github.com/opf/openproject-deploy"
dest: "{{ repository_directory }}" dest: "{{ repository_directory }}"
update: yes update: yes
force: yes
notify: recreate openproject notify: recreate openproject
become: true become: true
register: git_result register: git_result