From 81f8180aae74f45e652ed935c6978b8a4de0a839 Mon Sep 17 00:00:00 2001 From: Brenton Leanhardt Date: Wed, 9 Mar 2016 09:03:29 -0500 Subject: Bug 1315563 - Upgrade failed to containerized install OSE 3.1 on RHEL Previously I was greping for 'ose' in the systemd units. That was only working on my machine because my Nodes were also Masters. It's safer to grep for openshift3 since that would be present for Masters or Nodes. --- .../openshift-cluster/upgrades/files/openshift_container_versions.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'playbooks/common/openshift-cluster/upgrades') diff --git a/playbooks/common/openshift-cluster/upgrades/files/openshift_container_versions.sh b/playbooks/common/openshift-cluster/upgrades/files/openshift_container_versions.sh index ba17ca671..da6bcd23c 100644 --- a/playbooks/common/openshift-cluster/upgrades/files/openshift_container_versions.sh +++ b/playbooks/common/openshift-cluster/upgrades/files/openshift_container_versions.sh @@ -10,7 +10,7 @@ if [ ${1} == "origin" ]; then image_name="openshift/origin" elif grep aep $unit_file 2>&1 > /dev/null; then image_name="aep3/aep" -elif grep ose $unit_file 2>&1 > /dev/null; then +elif grep openshift3 $unit_file 2>&1 > /dev/null; then image_name="openshift3/ose" fi -- cgit v1.2.3 From 013f26b972d04a429e31dbe662e0e6eeb99d7f51 Mon Sep 17 00:00:00 2001 From: Brenton Leanhardt Date: Wed, 9 Mar 2016 09:48:55 -0500 Subject: Bug 1315564 - upgrade to ose3.2 failed on Atomic Hosts --- .../upgrades/v3_1_to_v3_2/docker_upgrade.yml | 30 +++++++++------------- .../upgrades/v3_1_to_v3_2/upgrade.yml | 13 ++++++++-- 2 files changed, 23 insertions(+), 20 deletions(-) (limited to 'playbooks/common/openshift-cluster/upgrades') diff --git a/playbooks/common/openshift-cluster/upgrades/v3_1_to_v3_2/docker_upgrade.yml b/playbooks/common/openshift-cluster/upgrades/v3_1_to_v3_2/docker_upgrade.yml index d384631d3..d9177e8a0 100644 --- a/playbooks/common/openshift-cluster/upgrades/v3_1_to_v3_2/docker_upgrade.yml +++ b/playbooks/common/openshift-cluster/upgrades/v3_1_to_v3_2/docker_upgrade.yml @@ -1,20 +1,14 @@ ---- -- name: Upgrade Docker - hosts: oo_masters_to_config:oo_nodes_to_config:oo_etcd_to_config - vars: - openshift_version: "{{ openshift_pkg_version | default('') }}" - tasks: - - name: Check if Docker is installed - command: rpm -q docker - register: pkg_check - failed_when: pkg_check.rc > 1 - changed_when: no +- name: Check if Docker is installed + command: rpm -q docker + register: pkg_check + failed_when: pkg_check.rc > 1 + changed_when: no - - name: Upgrade Docker - command: "{{ ansible_pkg_mgr}} update -y docker" - when: pkg_check.rc == 0 and g_docker_version.curr_version | version_compare('1.9','<') - register: docker_upgrade +- name: Upgrade Docker + command: "{{ ansible_pkg_mgr}} update -y docker" + when: pkg_check.rc == 0 and g_docker_version.curr_version | version_compare('1.9','<') + register: docker_upgrade - - name: Restart Docker - service: name=docker state=restarted - when: docker_upgrade | changed +- name: Restart Docker + service: name=docker state=restarted + when: docker_upgrade | changed diff --git a/playbooks/common/openshift-cluster/upgrades/v3_1_to_v3_2/upgrade.yml b/playbooks/common/openshift-cluster/upgrades/v3_1_to_v3_2/upgrade.yml index 3552b8734..d84d9f674 100644 --- a/playbooks/common/openshift-cluster/upgrades/v3_1_to_v3_2/upgrade.yml +++ b/playbooks/common/openshift-cluster/upgrades/v3_1_to_v3_2/upgrade.yml @@ -3,14 +3,21 @@ # The restart playbook should be run after this playbook completes. ############################################################################### -- include: docker_upgrade.yml - when: not openshift.common.is_atomic | bool +- name: Upgrade docker + hosts: oo_masters_to_config:oo_nodes_to_config:oo_etcd_to_config + roles: + - openshift_facts + tasks: + - include: docker_upgrade.yml + when: not openshift.common.is_atomic | bool ############################################################################### # Upgrade Masters ############################################################################### - name: Upgrade master hosts: oo_masters_to_config + roles: + - openshift_facts tasks: - include: rpm_upgrade.yml component=master when: not openshift.common.is_containerized | bool @@ -54,6 +61,8 @@ ############################################################################### - name: Upgrade nodes hosts: oo_nodes_to_config + roles: + - openshift_facts tasks: - include: rpm_upgrade.yml vars: -- cgit v1.2.3