summaryrefslogtreecommitdiffstats
path: root/roles/openshift_docker_facts
diff options
context:
space:
mode:
authorJason DeTiberus <jdetiber@redhat.com>2016-03-15 22:21:39 -0400
committerJason DeTiberus <jdetiber@redhat.com>2016-03-17 00:46:02 -0400
commitbc114a192e2682204aa237fb7d69009ddfa5b747 (patch)
tree081da29f0ab839e6530eb183dcb4ea6b44fcb14c /roles/openshift_docker_facts
parent4551e7cddf4a9d1756a064fd31777b6bed7d3567 (diff)
downloadopenshift-bc114a192e2682204aa237fb7d69009ddfa5b747.tar.gz
openshift-bc114a192e2682204aa237fb7d69009ddfa5b747.tar.bz2
openshift-bc114a192e2682204aa237fb7d69009ddfa5b747.tar.xz
openshift-bc114a192e2682204aa237fb7d69009ddfa5b747.zip
Bug 1317755 - Set insecure-registry for internal registry by default
Diffstat (limited to 'roles/openshift_docker_facts')
-rw-r--r--roles/openshift_docker_facts/tasks/main.yml17
1 files changed, 12 insertions, 5 deletions
diff --git a/roles/openshift_docker_facts/tasks/main.yml b/roles/openshift_docker_facts/tasks/main.yml
index ad7ad3748..26b46aa94 100644
--- a/roles/openshift_docker_facts/tasks/main.yml
+++ b/roles/openshift_docker_facts/tasks/main.yml
@@ -13,11 +13,9 @@
log_options: "{{ openshift_docker_log_options | default(None) }}"
options: "{{ openshift_docker_options | default(None) }}"
disable_push_dockerhub: "{{ openshift_disable_push_dockerhub | default(None) }}"
- - role: node
- local_facts:
- portal_net: "{{ openshift_master_portal_net | default(None) }}"
+ hosted_registry_insecure: "{{ openshift_docker_hosted_registry_insecure | default(None) }}"
+ hosted_registry_network: "{{ openshift_docker_hosted_registry_network | default(None) }}"
-# TODO: append openshift.node.portal_net to docker_insecure_registries
- set_fact:
docker_additional_registries: "{{ openshift.docker.additional_registries
| default(omit) }}"
@@ -27,6 +25,15 @@
| default(omit) }}"
docker_log_driver: "{{ openshift.docker.log_driver | default(omit) }}"
docker_log_options: "{{ openshift.docker.log_options | default(omit) }}"
- docker_options: "{{ openshift.docker.options | default(omit) }}"
docker_push_dockerhub: "{{ openshift.docker.disable_push_dockerhub
| default(omit) }}"
+
+- set_fact:
+ docker_options: >
+ --insecure-registry={{ openshift.docker.hosted_registry_network }}
+ {{ openshift.docker.options | default ('') }}
+ when: openshift.docker.hosted_registry_insecure | default(False) | bool
+
+- set_fact:
+ docker_options: "{{ openshift.docker.options | default(omit) }}"
+ when: not openshift.docker.hosted_registry_insecure | default(False) | bool