mirror of
https://github.com/containers/ansible-podman-collections.git
synced 2026-02-04 07:11:49 +00:00
Add another test for volumes (#942)
Signed-off-by: Sagi Shnaidman <sshnaidm@redhat.com>
This commit is contained in:
parent
6ff93e7559
commit
f6bd81e820
1 changed files with 14 additions and 1 deletions
|
|
@ -371,13 +371,26 @@
|
|||
- /tmp/data:/data:U
|
||||
register: test24
|
||||
|
||||
- name: Check test24
|
||||
- containers.podman.podman_container:
|
||||
executable: "{{ test_executable | default('podman') }}"
|
||||
name: test24
|
||||
image: alpine
|
||||
state: present
|
||||
volumes:
|
||||
- /tmp/data:/data:U
|
||||
register: test25
|
||||
|
||||
- name: Check volumes with selinux relabeling
|
||||
assert:
|
||||
that:
|
||||
- test24 is changed
|
||||
- >-
|
||||
(test24.container['Config']['CreateCommand'] is defined and
|
||||
'/tmp/data:/data:U' in test24.container['Config']['CreateCommand'] | list)
|
||||
- test25 is not changed
|
||||
- >-
|
||||
(test25.container['Config']['CreateCommand'] is defined and
|
||||
'/tmp/data:/data:U' in test25.container['Config']['CreateCommand'] | list)
|
||||
|
||||
- ansible.builtin.file:
|
||||
path: /tmp/data
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue