Don't die when docker CLI doesn't want to work with docker daemon (#366)

* Don't die when docker CLI doesn't want to work with docker daemon.

* Allow more 'docker volume ls' failures

* More.

* Fix more failures.

* Forgot ignore_errors.

* Another one.

* More places.

* Try to install newer docker on RHEL8.

* Also restrict docker-ce-cli.
This commit is contained in:
Felix Fontein 2020-05-20 08:40:04 +02:00 committed by GitHub
commit 6fca49f445
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 251 additions and 181 deletions

View file

@ -7,14 +7,20 @@
command: "docker logs {{ registry_name }}"
register: registry_logs
no_log: yes
ignore_errors: yes
- name: "Printing registry logs"
debug: var=registry_logs.stdout_lines
debug:
var: registry_logs.stdout_lines
when: registry_logs is not failed
- name: "Get nginx logs"
command: "docker logs {{ nginx_name }}"
register: nginx_logs
no_log: yes
ignore_errors: yes
- name: "Printing nginx logs"
debug: var=nginx_logs.stdout_lines
debug:
var: nginx_logs.stdout_lines
when: nginx_logs is not failed
- name: "Make sure all containers are removed"
docker_container:
name: "{{ item }}"