kolla-ansible/ansible/roles/baremetal/templates/docker_systemd_service.j2
Michal Nasiadka 7fa419cfc3 baremetal: Add support for Docker http/https proxy setup
Change-Id: I947c2940518c0f4872acaa977edeaca370dc9a96
2021-03-26 17:51:17 +00:00

14 lines
638 B
Django/Jinja

[Service]
{% if docker_http_proxy | length > 0 %}
Environment="HTTP_PROXY={{ docker_http_proxy }}"
{% endif %}
{% if docker_https_proxy | length > 0 %}
Environment="HTTPS_PROXY={{ docker_https_proxy }}"
{% endif %}
{% if docker_no_proxy | length > 0 %}
Environment="NO_PROXY={{ docker_no_proxy }}"
{% endif %}
ExecStart=
# ExecStart commandline copied from 'docker-ce' package. Same on CentOS/Debian/Ubuntu systems.
ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock{% if docker_custom_option %} {{ docker_custom_option }}{% endif %}{% if docker_configure_for_zun|bool %} {{ docker_zun_options }}{% endif %}