summaryrefslogtreecommitdiffstats
path: root/roles
diff options
context:
space:
mode:
authorBrenton Leanhardt <bleanhar@redhat.com>2015-09-02 16:55:17 -0400
committerBrenton Leanhardt <bleanhar@redhat.com>2015-09-02 16:55:17 -0400
commit7d480fbab74ddc8f76279f32c1a64148e5844382 (patch)
treeb9dcfc1a501b3e11a5ad1a64156eb5ee0f426c9b /roles
parent795a1d2c6a34d1ca3eb8e84325d9109d134e0a33 (diff)
parentc28aea2f19b6aea729f27b636e5318ac775addb6 (diff)
downloadopenshift-7d480fbab74ddc8f76279f32c1a64148e5844382.tar.gz
openshift-7d480fbab74ddc8f76279f32c1a64148e5844382.tar.bz2
openshift-7d480fbab74ddc8f76279f32c1a64148e5844382.tar.xz
openshift-7d480fbab74ddc8f76279f32c1a64148e5844382.zip
Merge pull request #544 from sdodson/serviceNetworkCIDR
Add serviceNetworkCIDR and SDN MTU config
Diffstat (limited to 'roles')
-rwxr-xr-xroles/openshift_facts/library/openshift_facts.py4
-rw-r--r--roles/openshift_master/templates/master.yaml.v1.j22
-rw-r--r--roles/openshift_node/tasks/main.yml1
-rw-r--r--roles/openshift_node/templates/node.yaml.v1.j27
4 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 334929c74..d4f38a7b4 100755
--- a/roles/openshift_facts/library/openshift_facts.py
+++ b/roles/openshift_facts/library/openshift_facts.py
@@ -488,6 +488,10 @@ def set_sdn_facts_if_unset(facts):
if 'sdn_host_subnet_length' not in facts['master']:
facts['master']['sdn_host_subnet_length'] = '8'
+ if 'node' in facts:
+ if 'sdn_mtu' not in facts['node']:
+ facts['node']['sdn_mtu'] = '1450'
+
return facts
def format_url(use_ssl, hostname, port, path=''):
diff --git a/roles/openshift_master/templates/master.yaml.v1.j2 b/roles/openshift_master/templates/master.yaml.v1.j2
index fff123d0d..7aa4ce9b6 100644
--- a/roles/openshift_master/templates/master.yaml.v1.j2
+++ b/roles/openshift_master/templates/master.yaml.v1.j2
@@ -88,6 +88,8 @@ networkConfig:
clusterNetworkCIDR: {{ openshift.master.sdn_cluster_network_cidr }}
hostSubnetLength: {{ openshift.master.sdn_host_subnet_length }}
networkPluginName: {{ openshift.common.sdn_network_plugin_name }}
+# serviceNetworkCIDR must match kubernetesMasterConfig.servicesSubnet
+ serviceNetworkCIDR: {{ openshift.master.portal_net }}
{% include 'v1_partials/oauthConfig.j2' %}
policyConfig:
bootstrapPolicyFile: {{ openshift_master_policy }}
diff --git a/roles/openshift_node/tasks/main.yml b/roles/openshift_node/tasks/main.yml
index db1731d65..e56a666e9 100644
--- a/roles/openshift_node/tasks/main.yml
+++ b/roles/openshift_node/tasks/main.yml
@@ -28,6 +28,7 @@
debug_level: "{{ openshift_node_debug_level | default(openshift.common.debug_level) }}"
portal_net: "{{ openshift_master_portal_net | default(None) }}"
kubelet_args: "{{ openshift_node_kubelet_args | default(None) }}"
+ sdn_mtu: "{{ openshift_node_sdn_mtu | default(None) }}"
- name: Install Node package
yum: pkg={{ openshift.common.service_type }}-node state=present
diff --git a/roles/openshift_node/templates/node.yaml.v1.j2 b/roles/openshift_node/templates/node.yaml.v1.j2
index e176e7511..0f708fb55 100644
--- a/roles/openshift_node/templates/node.yaml.v1.j2
+++ b/roles/openshift_node/templates/node.yaml.v1.j2
@@ -13,6 +13,11 @@ kubeletArguments: {{ openshift.node.kubelet_args | to_json }}
{% endif %}
masterKubeConfig: system:node:{{ openshift.common.hostname }}.kubeconfig
networkPluginName: {{ openshift.common.sdn_network_plugin_name }}
+# networkConfig struct introduced in origin 1.0.6 and OSE 3.0.2 which
+# deprecates networkPluginName above. The two should match.
+networkConfig:
+ mtu: {{ openshift.node.sdn_mtu }}
+ networkPluginName: {{ openshift.common.sdn_network_plugin_name }}
nodeName: {{ openshift.common.hostname }}
podManifestConfig:
servingInfo:
@@ -21,4 +26,4 @@ servingInfo:
clientCA: ca.crt
keyFile: server.key
volumeDirectory: {{ openshift_data_dir }}/openshift.local.volumes
-{% include 'partials/kubeletArguments.j2' %} \ No newline at end of file
+{% include 'partials/kubeletArguments.j2' %}