aboutsummaryrefslogtreecommitdiffstats
path: root/ansible/roles/docker/templates/http-proxy-conf.j2
diff options
context:
space:
mode:
Diffstat (limited to 'ansible/roles/docker/templates/http-proxy-conf.j2')
-rw-r--r--ansible/roles/docker/templates/http-proxy-conf.j22
1 files changed, 2 insertions, 0 deletions
diff --git a/ansible/roles/docker/templates/http-proxy-conf.j2 b/ansible/roles/docker/templates/http-proxy-conf.j2
new file mode 100644
index 000000000..854ddfe09
--- /dev/null
+++ b/ansible/roles/docker/templates/http-proxy-conf.j2
@@ -0,0 +1,2 @@
+[Service]
+Environment={% if "http_proxy" in proxy_env %}"HTTP_PROXY={{ proxy_env.http_proxy }}" {% endif %} {% if "https_proxy" in proxy_env %} "HTTPS_PROXY={{ proxy_env.https_proxy }}" {% endif %} {% if "http_proxy" in proxy_env or "https_proxy" in proxy_env %} "NO_PROXY=localhost,127.0.0.0/8" {% endif %}