Skip to content

Commit 117421d

Browse files
committed
add Ansible conditional
1 parent dd8736e commit 117421d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

shared/applicability/bootc.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@ title: Bootable containers
1313
# Bootable containers and running bootc systems both contain these packages.
1414
# Normal bare-metal systems usually don't have the rpm-ostree, normal
1515
# containers don't contain kernel.
16-
#
16+
# Also normal containers are not supposed to have the /run/ostree-booted file.
1717
check_id: bootc
1818
{{% if product == "fedora" or "rhel" in product %}}
1919
{{% set kernel_package = "kernel-core" %}}
2020
{{% else %}}
2121
{{% set kernel_package = "kernel" %}}
2222
{{% endif %}}
2323
bash_conditional: "{ rpm --quiet -q {{{ kernel_package }}} ;} && { rpm --quiet -q rpm-ostree ;} && { rpm --quiet -q bootc ;} && { ! rpm --quiet -q openshift-kubelet ;} && [ -f /run/ostree-booted ]"
24-
ansible_conditional: '"{{{ kernel_package }}}" in ansible_facts.packages and "rpm-ostree" in ansible_facts.packages and "bootc" in ansible_facts.packages and not "openshift-kubelet" in ansible_facts.packages'
24+
ansible_conditional: '"{{{ kernel_package }}}" in ansible_facts.packages and "rpm-ostree" in ansible_facts.packages and "bootc" in ansible_facts.packages and not "openshift-kubelet" in ansible_facts.packages and "ostree" in ansible_proc_cmdline'

0 commit comments

Comments
 (0)