Compose v2: improve parsing of dry-run building JSON events (#976)

* Catch more warnings that shouldn't be there.

* Add explicit handling of dry-run image build JSON events.

These produce some one-off ID values that don't make any sense as ID values.
This commit is contained in:
Felix Fontein
2024-10-14 20:56:49 +02:00
committed by GitHub
parent ea38591dec
commit 28e87f4602
7 changed files with 349 additions and 64 deletions
@@ -14,6 +14,7 @@
name_prefix: "{{ 'ansible-docker-test-%0x' % ((2**32) | random) }}"
cnames: []
dnetworks: []
images: []
- debug:
msg: "Using name prefix {{ name_prefix }}"
@@ -35,7 +36,7 @@
name: "{{ item }}"
state: absent
force_kill: true
with_items: "{{ cnames }}"
loop: "{{ cnames }}"
diff: false
- name: "Make sure all networks are removed"
@@ -43,7 +44,13 @@
name: "{{ item }}"
state: absent
force: true
with_items: "{{ dnetworks }}"
loop: "{{ dnetworks }}"
diff: false
- name: "Make sure all images are removed"
docker_image_remove:
name: "{{ item }}"
loop: "{{ images }}"
diff: false
when: docker_has_compose and docker_compose_version is version('2.18.0', '>=')