summaryrefslogtreecommitdiffstats
path: root/roles
diff options
context:
space:
mode:
authorTroy Dawson <tdawson@redhat.com>2015-06-12 17:10:02 -0500
committerTroy Dawson <tdawson@redhat.com>2015-06-12 17:10:02 -0500
commit15df494fb781dd1509854eeb366e981930b52c22 (patch)
tree6f2aa57ffdfceee3e7170d0648fce9979c6a2f91 /roles
parentc650920bc7b0043e59fa3439f48f61d5fa211f2d (diff)
parentffb8bbe2fd6b85ab0f2c108292034931edae1747 (diff)
downloadopenshift-15df494fb781dd1509854eeb366e981930b52c22.tar.gz
openshift-15df494fb781dd1509854eeb366e981930b52c22.tar.bz2
openshift-15df494fb781dd1509854eeb366e981930b52c22.tar.xz
openshift-15df494fb781dd1509854eeb366e981930b52c22.zip
Merge branch 'master' into prod
Diffstat (limited to 'roles')
-rwxr-xr-xroles/openshift_facts/library/openshift_facts.py2
-rw-r--r--roles/openshift_node/tasks/main.yml12
2 files changed, 13 insertions, 1 deletions
diff --git a/roles/openshift_facts/library/openshift_facts.py b/roles/openshift_facts/library/openshift_facts.py
index e4d3bf26f..cb67a13de 100755
--- a/roles/openshift_facts/library/openshift_facts.py
+++ b/roles/openshift_facts/library/openshift_facts.py
@@ -705,7 +705,7 @@ class OpenShiftFacts(object):
defaults['master'] = master
if 'node' in roles:
- node = dict(pod_cidr='', labels={}, annotations={})
+ node = dict(pod_cidr='', labels={}, annotations={}, portal_net='172.30.0.0/16')
node['resources_cpu'] = self.system_facts['processor_cores']
node['resources_memory'] = int(
int(self.system_facts['memtotal_mb']) * 1024 * 1024 * 0.75
diff --git a/roles/openshift_node/tasks/main.yml b/roles/openshift_node/tasks/main.yml
index c5202650f..15d18f510 100644
--- a/roles/openshift_node/tasks/main.yml
+++ b/roles/openshift_node/tasks/main.yml
@@ -20,6 +20,7 @@
annotations: "{{ openshift_node_annotations | default(none) }}"
registry_url: "{{ oreg_url | default(none) }}"
debug_level: "{{ openshift_node_debug_level | default(openshift.common.debug_level) }}"
+ portal_net: "{{ openshift_master_portal_net | default(None) }}"
- name: Install OpenShift Node package
yum: pkg=openshift-node state=present
@@ -56,6 +57,17 @@
notify:
- restart openshift-node
+- stat: path=/etc/sysconfig/docker
+ register: docker_check
+
+ # TODO: Enable secure registry when code available in origin
+- name: Secure OpenShift Registry
+ lineinfile:
+ dest: /etc/sysconfig/docker
+ regexp: '^OPTIONS=.*'
+ line: "OPTIONS='--insecure-registry={{ openshift.node.portal_net }} --selinux-enabled'"
+ when: docker_check.stat.isreg
+
- name: Allow NFS access for VMs
seboolean: name=virt_use_nfs state=yes persistent=yes