1 #Copyright 2018 OPNFV and Intel Corporation
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
16 - name: create docker proxy configuration file
20 path: "{{ docker_proxy_conf }}"
24 - name: add docker http_proxy
28 path: "{{ docker_proxy_conf }}"
29 line: "Environment=\"HTTP_PROXY={{ ansible_env.http_proxy }}\""
30 when: ansible_env.http_proxy is defined
32 - name: add docker https_proxy
36 path: "{{ docker_proxy_conf }}"
37 line: "Environment=\"HTTPS_PROXY={{ ansible_env.https_proxy }}\""
38 when: ansible_env.https_proxy is defined
40 - name: add docker ftp_proxy
44 path: "{{ docker_proxy_conf }}"
45 line: "Environment=\"FTP_PROXY={{ ansible_env.ftp_proxy }}\""
46 when: ansible_env.ftp_proxy is defined
48 - name: add docker no_proxy
52 path: "{{ docker_proxy_conf }}"
53 line: "Environment=\"NO_PROXY={{ ansible_env.no_proxy }}\""
54 when: ansible_env.no_proxy is defined