summaryrefslogtreecommitdiffstats
path: root/playbooks/adhoc
diff options
context:
space:
mode:
authorJason DeTiberus <jdetiber@redhat.com>2015-11-06 15:59:29 -0500
committerJason DeTiberus <jdetiber@redhat.com>2015-11-06 15:59:29 -0500
commite38eae135ac4957576b263c3cc8f50e9805ea937 (patch)
treea93f4b7a06b7be0706d6e604cdd0b6bfc2684b73 /playbooks/adhoc
parenteec5e61daf1bd0ef773c21180ae642fafe23e3df (diff)
parent0cfb416780b9e86c26eafd62ee6b99cd2a46b7cd (diff)
downloadopenshift-e38eae135ac4957576b263c3cc8f50e9805ea937.tar.gz
openshift-e38eae135ac4957576b263c3cc8f50e9805ea937.tar.bz2
openshift-e38eae135ac4957576b263c3cc8f50e9805ea937.tar.xz
openshift-e38eae135ac4957576b263c3cc8f50e9805ea937.zip
Merge remote-tracking branch 'dgoodwin/pre-upgrade' into upgradeFix2
Diffstat (limited to 'playbooks/adhoc')
-rw-r--r--playbooks/adhoc/upgrades/files/pre-upgrade-check7
-rw-r--r--playbooks/adhoc/upgrades/upgrade.yml12
2 files changed, 12 insertions, 7 deletions
diff --git a/playbooks/adhoc/upgrades/files/pre-upgrade-check b/playbooks/adhoc/upgrades/files/pre-upgrade-check
index c8ecae399..ed4ab6d1b 100644
--- a/playbooks/adhoc/upgrades/files/pre-upgrade-check
+++ b/playbooks/adhoc/upgrades/files/pre-upgrade-check
@@ -131,8 +131,11 @@ def main():
print "found"
except:
print(
- 'Can not find oc (%s). Override the path with the '
- 'OC_PATH environment variable. Exiting...' % OC_PATH)
+ 'Unable to run "%s whoami"\n'
+ 'Please ensure OpenShift is running, and "oc" is on your system '
+ 'path.\n'
+ 'You can override the path with the OC_PATH environment variable.'
+ % OC_PATH)
raise SystemExit(1)
# Where the magic happens
diff --git a/playbooks/adhoc/upgrades/upgrade.yml b/playbooks/adhoc/upgrades/upgrade.yml
index 02847eab3..09c472e58 100644
--- a/playbooks/adhoc/upgrades/upgrade.yml
+++ b/playbooks/adhoc/upgrades/upgrade.yml
@@ -10,11 +10,6 @@
openshift_master_ha: "{{ groups['masters'] | length > 1 }}"
gather_facts: no
tasks:
- # Checking the global deployment type rather than host facts, this is about
- # what the user is requesting.
- - fail:
- msg: "Deployment type enterprise not supported for upgrade"
- when: deployment_type == "enterprise"
# Pacemaker is currently the only supported upgrade path for multiple masters
- fail:
msg: "openshift_master_cluster_method must be set to 'pacemaker'"
@@ -132,6 +127,12 @@
- fail:
msg: Atomic OpenShift 3.1 packages not found
when: deployment_type in ['openshift-enterprise', 'atomic-openshift'] and g_aos_versions.curr_version | version_compare('3.0.2.900','<') and (g_aos_versions.avail_version is none or g_aos_versions.avail_version | version_compare('3.0.2.900','<'))
+ # Deployment type 'enterprise' is no longer valid if we're upgrading to 3.1 or beyond.
+ # (still valid for 3.0.x to 3.0.y however) Using the global deployment_type here as
+ # we're checking what was requested by the upgrade, not the current type on the system.
+ - fail:
+ msg: "Deployment type enterprise not supported for upgrade"
+ when: deployment_type == "enterprise" and g_aos_versions.curr_version | version_compare('3.1', '>=')
- name: Upgrade masters
@@ -158,6 +159,7 @@
to_version: '3.1'
role: master
config_base: "{{ hostvars[inventory_hostname].openshift.common.config_base }}"
+ when: deployment_type in ['openshift-enterprise', 'atomic-enterprise'] and g_aos_versions.curr_version | version_compare('3.1', '>=')
- set_fact:
master_certs_missing: True