Improve tasks, show images before docker_compose_v2_pull tests.

This commit is contained in:
Felix Fontein 2024-05-10 13:06:54 +02:00
parent a4a05e7fa5
commit e176a8a17b
5 changed files with 13 additions and 5 deletions

View File

@ -20,7 +20,8 @@
# Run the tests
- block:
- command: docker compose --help
- name: Show docker compose --help output
command: docker compose --help
- include_tasks: run-test.yml
with_fileglob:

View File

@ -18,9 +18,13 @@
- debug:
msg: "Using name prefix {{ name_prefix }}"
- name: Show images
command: docker images --all --digests
# Run the tests
- block:
- command: docker compose --help
- name: Show docker compose --help output
command: docker compose --help
- include_tasks: run-test.yml
with_fileglob:

View File

@ -174,7 +174,8 @@
- (output_direct.host_info | sanitize_host_info) == (output_https.host_info | sanitize_host_info)
always:
- command: docker logs {{ daemon_nginx_frontend }}
- name: Obtain logs from the nginx frontend
command: docker logs {{ daemon_nginx_frontend }}
register: output
ignore_errors: true
- debug:

View File

@ -91,7 +91,8 @@
- block:
# Cleanup docker daemon
- command: 'docker ps --no-trunc --format {% raw %}"{{.Names}}"{% endraw %}'
- name: Show all containers
command: 'docker ps --no-trunc --format {% raw %}"{{.Names}}"{% endraw %}'
- name: "Remove all ansible-docker-test-* docker containers"
shell: 'docker ps --no-trunc --format {% raw %}"{{.Names}}"{% endraw %} | grep "^ansible-docker-test-" | xargs -r docker rm -f'

View File

@ -52,7 +52,8 @@
- name: Obtain Docker Compose version
when: docker_has_compose
block:
- command:
- name: Obtain docker info
command:
cmd: docker info --format '{% raw %}{{ json .ClientInfo.Plugins }}{% endraw %}'
register: docker_cli_plugins_stdout
- set_fact: