From f20e3bf3557451047a3ab035de503cd2ce35a550 Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Sun, 21 May 2023 19:01:59 +0200 Subject: fix some ansible-lint warnings --- roles/my_server/tasks/main.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'roles/my_server') diff --git a/roles/my_server/tasks/main.yml b/roles/my_server/tasks/main.yml index 36cb4cc..eaf6aa5 100644 --- a/roles/my_server/tasks/main.yml +++ b/roles/my_server/tasks/main.yml @@ -1,14 +1,14 @@ - name: 'Check if {{ server_dir }}/docker-compose.yml exists' become: true - stat: + ansible.builtin.stat: path: '{{ server_dir }}/docker-compose.yml' register: server_exists -- when: server_exists.stat.exists - name: Update containers +- name: Update containers + when: server_exists.stat.exists become: true # community.docker.docker_compose is too confusing for me to use, sorry. - shell: | + ansible.builtin.shell: | docker-compose pull -q && \ docker-compose build --force-rm --pull -q && \ docker-compose up --remove-orphans -d -- cgit v1.2.3