Replace injected Ansible fact variables in container-engine role (#13296)

This commit is contained in:
Nikhil Kumar
2026-06-16 08:51:24 +05:30
committed by GitHub
parent a76a475a5b
commit e0add9ee0d
21 changed files with 322 additions and 320 deletions

View File

@@ -4,7 +4,7 @@ Environment="DOCKER_OPTS={{ docker_options|default('') }} --iptables={{ docker_i
{% for i in docker_insecure_registries %}--insecure-registry={{ i }} {% endfor %} \
{% for i in docker_registry_mirrors %}--registry-mirror={{ i }} {% endfor %} \
--data-root={{ docker_daemon_graph }} \
{% if ansible_os_family not in ["openSUSE Leap", "openSUSE Tumbleweed", "Suse"] %}{{ docker_log_opts }}{% endif %}"
{% if ansible_facts['os_family'] not in ["openSUSE Leap", "openSUSE Tumbleweed", "Suse"] %}{{ docker_log_opts }}{% endif %}"
{% if docker_mount_flags is defined and docker_mount_flags != "" %}
MountFlags={{ docker_mount_flags }}

View File

@@ -2,7 +2,7 @@
Description=Docker Application Container Engine
Documentation=http://docs.docker.com
After=network.target docker.socket containerd.service lvm2-monitor.service SuSEfirewall2.service
{% if ansible_os_family != "Suse" %}
{% if ansible_facts['os_family'] != "Suse" %}
BindsTo=containerd.service
{% endif %}
Wants=docker.socket
@@ -17,7 +17,7 @@ ExecReload=/bin/kill -s HUP $MAINPID
Delegate=yes
KillMode=process
ExecStart={{ docker_bin_dir }}/dockerd \
{% if ansible_os_family == "Suse" %}
{% if ansible_facts['os_family'] == "Suse" %}
--add-runtime oci=/usr/sbin/docker-runc \
{% endif %}
$DOCKER_OPTS \