summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Butcher <abutcher@redhat.com>2015-10-26 15:20:35 -0400
committerAndrew Butcher <abutcher@redhat.com>2015-11-06 16:35:09 -0500
commit3d87d37f53712fbc7cadbf0829743d9a97e93ad1 (patch)
tree92efd57c773dece8151cfc0c44309b50c9ae32b8
parentf1f22218739982f768e36cc2695a1b4ab5561ca7 (diff)
downloadopenshift-3d87d37f53712fbc7cadbf0829743d9a97e93ad1.tar.gz
openshift-3d87d37f53712fbc7cadbf0829743d9a97e93ad1.tar.bz2
openshift-3d87d37f53712fbc7cadbf0829743d9a97e93ad1.tar.xz
openshift-3d87d37f53712fbc7cadbf0829743d9a97e93ad1.zip
New `iptablesSyncPeriod` field in node configuration
-rw-r--r--inventory/byo/hosts.example3
-rwxr-xr-xroles/openshift_facts/library/openshift_facts.py3
-rw-r--r--roles/openshift_node/tasks/main.yml13
-rw-r--r--roles/openshift_node/templates/node.yaml.v1.j21
4 files changed, 13 insertions, 7 deletions
diff --git a/inventory/byo/hosts.example b/inventory/byo/hosts.example
index 11f076a8a..f124be368 100644
--- a/inventory/byo/hosts.example
+++ b/inventory/byo/hosts.example
@@ -129,6 +129,9 @@ openshift_master_identity_providers=[{'name': 'htpasswd_auth', 'login': 'true',
# characters long, to select AES-128, AES-192, or AES-256.
#openshift_master_session_encryption_secrets=['DONT+USE+THIS+SECRET+b4NV+pmZNSO']
+# configure how often node iptables rules are refreshed
+#openshift_node_iptables_sync_period=5s
+
# host group for masters
[masters]
ose3-master[1:3]-ansible.test.example.com
diff --git a/roles/openshift_facts/library/openshift_facts.py b/roles/openshift_facts/library/openshift_facts.py
index 33aca987d..ea2c45e6c 100755
--- a/roles/openshift_facts/library/openshift_facts.py
+++ b/roles/openshift_facts/library/openshift_facts.py
@@ -961,7 +961,8 @@ class OpenShiftFacts(object):
defaults['master'] = master
if 'node' in roles:
- node = dict(labels={}, annotations={}, portal_net='172.30.0.0/16')
+ node = dict(labels={}, annotations={}, portal_net='172.30.0.0/16',
+ iptables_sync_period='5s')
defaults['node'] = node
return defaults
diff --git a/roles/openshift_node/tasks/main.yml b/roles/openshift_node/tasks/main.yml
index 7525c12f6..d11bc5123 100644
--- a/roles/openshift_node/tasks/main.yml
+++ b/roles/openshift_node/tasks/main.yml
@@ -22,16 +22,17 @@
deployment_type: "{{ openshift_deployment_type }}"
- role: node
local_facts:
- labels: "{{ lookup('oo_option', 'openshift_node_labels') | default( openshift_node_labels | default(none), true) }}"
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) }}"
- kubelet_args: "{{ openshift_node_kubelet_args | default(None) }}"
- sdn_mtu: "{{ openshift_node_sdn_mtu | default(None) }}"
- schedulable: "{{ openshift_schedulable | default(openshift_scheduleable) | default(None) }}"
docker_log_driver: "{{ lookup( 'oo_option' , 'docker_log_driver' ) | default('',True) }}"
docker_log_options: "{{ lookup( 'oo_option' , 'docker_log_options' ) | default('',True) }}"
+ iptables_sync_period: "{{ openshift_node_iptables_sync_period | default(None) }}"
+ kubelet_args: "{{ openshift_node_kubelet_args | default(None) }}"
+ labels: "{{ lookup('oo_option', 'openshift_node_labels') | default( openshift_node_labels | default(none), true) }}"
+ portal_net: "{{ openshift_master_portal_net | default(None) }}"
+ registry_url: "{{ oreg_url | default(none) }}"
+ schedulable: "{{ openshift_schedulable | default(openshift_scheduleable) | default(None) }}"
+ sdn_mtu: "{{ openshift_node_sdn_mtu | default(None) }}"
storage_plugin_deps: "{{ osn_storage_plugin_deps | default(None) }}"
# We have to add tuned-profiles in the same transaction otherwise we run into depsolving
diff --git a/roles/openshift_node/templates/node.yaml.v1.j2 b/roles/openshift_node/templates/node.yaml.v1.j2
index 509cce2e0..7d2f506e3 100644
--- a/roles/openshift_node/templates/node.yaml.v1.j2
+++ b/roles/openshift_node/templates/node.yaml.v1.j2
@@ -4,6 +4,7 @@ dnsDomain: {{ osn_cluster_dns_domain }}
dnsIP: {{ osn_cluster_dns_ip }}
dockerConfig:
execHandlerName: ""
+iptablesSyncPeriod: "{{ openshift.node.iptables_sync_period }}"
imageConfig:
format: {{ openshift.node.registry_url }}
latest: false