1
0
Fork 0
forked from infra/ansible

releng-compose: fix the actual ordering/logic error here.

'foo or bar in group_names' is evaluated by ansible as 'foo' or 'bar in
group_names' which turns out to always be true because 'foo' by itself
is true.

So, fix the logic here to test each group and or them together.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
This commit is contained in:
Kevin Fenzi 2025-08-09 13:42:39 -07:00
commit 6e3f6e9ac3

View file

@ -66,7 +66,7 @@
- role: nfs/client
mnt_dir: '/mnt/fedora_koji'
nfs_src_dir: "{{ koji_hub_nfs }}"
when: "'releng_compose' or 'releng_compose_eln' in group_names"
when: "'releng_compose' in group_names or 'releng_compose_eln' in group_names"
- role: nfs/client
mnt_dir: '/mnt/koji/ostree'
nfs_src_dir: 'fedora_ostree_content/ostree'
@ -86,7 +86,7 @@
- role: nfs/client
mnt_dir: '/pub'
nfs_src_dir: 'fedora_ftp/fedora.redhat.com/pub'
when: "'releng_compose' or 'releng_compose_eln' in group_names and 'releng_compose_riscv' not in group_names"
when: "'releng_compose' in group_names or 'releng_compose_eln' in group_names"
- role: nfs/client
mnt_dir: '/mnt/fedora_riscv_koji'
nfs_src_dir: "{{ koji_hub_nfs }}"