summaryrefslogtreecommitdiffstats
path: root/playbooks/common/openshift-cluster/upgrades
diff options
context:
space:
mode:
authorOpenShift Bot <eparis+openshiftbot@redhat.com>2017-05-18 09:33:51 -0500
committerGitHub <noreply@github.com>2017-05-18 09:33:51 -0500
commited988a68bd6edce0d91e2aa0b20e6dd8327863be (patch)
tree1ff0cc5daa570522df7b262f6143b195ea74bc2a /playbooks/common/openshift-cluster/upgrades
parentb1c0247fdeb01f46e885c57cd272786d00ac8490 (diff)
parentc5c222eddb0b8950995105c4c406f5a5d0bfbacd (diff)
downloadopenshift-ed988a68bd6edce0d91e2aa0b20e6dd8327863be.tar.gz
openshift-ed988a68bd6edce0d91e2aa0b20e6dd8327863be.tar.bz2
openshift-ed988a68bd6edce0d91e2aa0b20e6dd8327863be.tar.xz
openshift-ed988a68bd6edce0d91e2aa0b20e6dd8327863be.zip
Merge pull request #4176 from mtnbikenc/refactor-openshift_excluders
Merged by openshift-bot
Diffstat (limited to 'playbooks/common/openshift-cluster/upgrades')
-rw-r--r--playbooks/common/openshift-cluster/upgrades/disable_master_excluders.yml18
-rw-r--r--playbooks/common/openshift-cluster/upgrades/disable_node_excluders.yml18
-rw-r--r--playbooks/common/openshift-cluster/upgrades/post_control_plane.yml8
-rw-r--r--playbooks/common/openshift-cluster/upgrades/upgrade_nodes.yml13
4 files changed, 23 insertions, 34 deletions
diff --git a/playbooks/common/openshift-cluster/upgrades/disable_master_excluders.yml b/playbooks/common/openshift-cluster/upgrades/disable_master_excluders.yml
index 35da3b6c3..800621857 100644
--- a/playbooks/common/openshift-cluster/upgrades/disable_master_excluders.yml
+++ b/playbooks/common/openshift-cluster/upgrades/disable_master_excluders.yml
@@ -2,13 +2,11 @@
- name: Disable excluders
hosts: oo_masters_to_config
gather_facts: no
- tasks:
- - include_role:
- name: openshift_excluder
- tasks_from: verify_upgrade
- - include_role:
- name: openshift_excluder
- tasks_from: disable
- vars:
- openshift_excluder_package_state: latest
- docker_excluder_package_state: latest
+ roles:
+ - role: openshift_excluder
+ r_openshift_excluder_action: disable
+ r_openshift_excluder_service_type: "{{ openshift.common.service_type }}"
+ r_openshift_excluder_verify_upgrade: true
+ r_openshift_excluder_upgrade_target: "{{ openshift_upgrade_target }}"
+ r_openshift_excluder_package_state: latest
+ r_openshift_excluder_docker_package_state: latest
diff --git a/playbooks/common/openshift-cluster/upgrades/disable_node_excluders.yml b/playbooks/common/openshift-cluster/upgrades/disable_node_excluders.yml
index 847c22085..7988e97ab 100644
--- a/playbooks/common/openshift-cluster/upgrades/disable_node_excluders.yml
+++ b/playbooks/common/openshift-cluster/upgrades/disable_node_excluders.yml
@@ -2,13 +2,11 @@
- name: Disable excluders
hosts: oo_nodes_to_config
gather_facts: no
- tasks:
- - include_role:
- name: openshift_excluder
- tasks_from: verify_upgrade
- - include_role:
- name: openshift_excluder
- tasks_from: disable
- vars:
- openshift_excluder_package_state: latest
- docker_excluder_package_state: latest
+ roles:
+ - role: openshift_excluder
+ r_openshift_excluder_action: disable
+ r_openshift_excluder_service_type: "{{ openshift.common.service_type }}"
+ r_openshift_excluder_verify_upgrade: true
+ r_openshift_excluder_upgrade_target: "{{ openshift_upgrade_target }}"
+ r_openshift_excluder_package_state: latest
+ r_openshift_excluder_docker_package_state: latest
diff --git a/playbooks/common/openshift-cluster/upgrades/post_control_plane.yml b/playbooks/common/openshift-cluster/upgrades/post_control_plane.yml
index 8a60ef236..9b76f1dd0 100644
--- a/playbooks/common/openshift-cluster/upgrades/post_control_plane.yml
+++ b/playbooks/common/openshift-cluster/upgrades/post_control_plane.yml
@@ -124,7 +124,7 @@
tags:
- always
gather_facts: no
- tasks:
- - include_role:
- name: openshift_excluder
- tasks_from: enable
+ roles:
+ - role: openshift_excluder
+ r_openshift_excluder_action: enable
+ r_openshift_excluder_service_type: "{{ openshift.common.service_type }}"
diff --git a/playbooks/common/openshift-cluster/upgrades/upgrade_nodes.yml b/playbooks/common/openshift-cluster/upgrades/upgrade_nodes.yml
index 2a5ac0aef..4d455fe0a 100644
--- a/playbooks/common/openshift-cluster/upgrades/upgrade_nodes.yml
+++ b/playbooks/common/openshift-cluster/upgrades/upgrade_nodes.yml
@@ -34,6 +34,9 @@
- openshift_facts
- docker
- openshift_node_upgrade
+ - role: openshift_excluder
+ r_openshift_excluder_action: enable
+ r_openshift_excluder_service_type: "{{ openshift.common.service_type }}"
post_tasks:
- name: Set node schedulability
@@ -46,13 +49,3 @@
register: node_schedulable
until: node_schedulable|succeeded
when: node_unschedulable|changed
-
-- name: Re-enable excluder if it was previously enabled
- hosts: oo_nodes_to_config
- tags:
- - always
- gather_facts: no
- tasks:
- - include_role:
- name: openshift_excluder
- tasks_from: enable