fix: Skip volume creation if not defined

This commit is contained in:
pulsar89.5 2024-02-26 14:11:31 +01:00
parent 64fbcbdd3e
commit 5da0939180

View File

@ -24,7 +24,7 @@
- name: Créer le volume - name: Créer le volume
containers.podman.podman_volume: containers.podman.podman_volume:
name: "{{ item.split(':')[0] }}" name: "{{ item.split(':')[0] }}"
when: container.volumes | length > 0 when: container.get('volumes', []) | length > 0
loop: "{{ container.volumes }}" loop: "{{ container.volumes }}"
- name: Déployer le conteneur - name: Déployer le conteneur