diff options
author | OpenShift Bot <eparis+openshiftbot@redhat.com> | 2017-05-17 09:37:24 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-17 09:37:24 -0500 |
commit | dbc331f77a08df52088ef72a138b6f4e3f654720 (patch) | |
tree | 37cfb9f62d299c05b5a116d0128f2c26d74e7a30 /roles | |
parent | 0090be3aa291b7c02190928dea96ffbaa3faf1ce (diff) | |
parent | 9bc76803f5a14648e367668028fd4386d2cfe56e (diff) | |
download | openshift-dbc331f77a08df52088ef72a138b6f4e3f654720.tar.gz openshift-dbc331f77a08df52088ef72a138b6f4e3f654720.tar.bz2 openshift-dbc331f77a08df52088ef72a138b6f4e3f654720.tar.xz openshift-dbc331f77a08df52088ef72a138b6f4e3f654720.zip |
Merge pull request #4173 from ashcrow/1450310
Merged by openshift-bot
Diffstat (limited to 'roles')
-rw-r--r-- | roles/docker/tasks/systemcontainer_docker.yml | 27 |
1 files changed, 22 insertions, 5 deletions
diff --git a/roles/docker/tasks/systemcontainer_docker.yml b/roles/docker/tasks/systemcontainer_docker.yml index c85801546..3af3e00b2 100644 --- a/roles/docker/tasks/systemcontainer_docker.yml +++ b/roles/docker/tasks/systemcontainer_docker.yml @@ -41,25 +41,38 @@ daemon_reload: yes ignore_errors: True -# Set http_proxy and https_proxy in /etc/atomic.conf +# Set http_proxy, https_proxy, and no_proxy in /etc/atomic.conf +# regexp: the line starts with or without #, followed by the string +# http_proxy, then either : or = - block: - name: Add http_proxy to /etc/atomic.conf lineinfile: - path: /etc/atomic.conf - line: "http_proxy={{ openshift.common.http_proxy | default('') }}" + dest: /etc/atomic.conf + regexp: "^#?http_proxy[:=]{1}" + line: "http_proxy: {{ openshift.common.http_proxy | default('') }}" when: - openshift.common.http_proxy is defined - openshift.common.http_proxy != '' - name: Add https_proxy to /etc/atomic.conf lineinfile: - path: /etc/atomic.conf - line: "https_proxy={{ openshift.common.https_proxy | default('') }}" + dest: /etc/atomic.conf + regexp: "^#?https_proxy[:=]{1}" + line: "https_proxy: {{ openshift.common.https_proxy | default('') }}" when: - openshift.common.https_proxy is defined - openshift.common.https_proxy != '' + - name: Add no_proxy to /etc/atomic.conf + lineinfile: + dest: /etc/atomic.conf + regexp: "^#?no_proxy[:=]{1}" + line: "no_proxy: {{ openshift.common.no_proxy | default('') }}" + when: + - openshift.common.no_proxy is defined + - openshift.common.no_proxy != '' + - block: - name: Set to default prepend @@ -88,9 +101,13 @@ set_fact: l_docker_image: "{{ l_docker_image_prepend }}/{{ openshift.docker.service_name }}:latest" +# NOTE: no_proxy added as a workaround until https://github.com/projectatomic/atomic/pull/999 is released - name: Pre-pull Container Enginer System Container image command: "atomic pull --storage ostree {{ l_docker_image }}" changed_when: false + environment: + NO_PROXY: "{{ openshift.common.no_proxy | default('') }}" + - name: Ensure container-engine.service.d directory exists file: |