From fa8f17557a152cf0da98f66403cfeb65dce68732 Mon Sep 17 00:00:00 2001 From: Devan Goodwin Date: Fri, 17 Jun 2016 11:01:11 -0300 Subject: Document the new and old version variables. --- inventory/byo/hosts.aep.example | 17 +++++++++++++++++ inventory/byo/hosts.origin.example | 17 +++++++++++++++++ inventory/byo/hosts.ose.example | 17 +++++++++++++++++ 3 files changed, 51 insertions(+) (limited to 'inventory') diff --git a/inventory/byo/hosts.aep.example b/inventory/byo/hosts.aep.example index 1e050f0f6..ffed3c042 100644 --- a/inventory/byo/hosts.aep.example +++ b/inventory/byo/hosts.aep.example @@ -24,6 +24,23 @@ debug_level=2 # deployment type valid values are origin, online, atomic-enterprise, and openshift-enterprise deployment_type=atomic-enterprise +# Specify the generic release of OpenShift to install. This is used mainly just during installation, after which we +# rely on the version running on the first master. Works best for containerized installs where we can usually +# use this to lookup the latest exact version of the container images, which is the tag actually used to configure +# the cluster. For RPM installations we just verify the version detected in your configured repos matches this +# release. +openshift_release=v3.2 + +# Specify an exact container image tag to install or configure. +# WARNING: This value will be used for all hosts in containerized environments, even those that have another version installed. +# This could potentially trigger an upgrade and downtime, so be careful with modifying this value after the cluster is set up. +#openshift_image_tag=v3.2.0.46 + +# Specify an exact rpm version to install or configure. +# WARNING: This value will be used for all hosts in RPM based environments, even those that have another version installed. +# This could potentially trigger an upgrade and downtime, so be careful with modifying this value after the cluster is set up. +#openshift_image_tag=-3.2.0.46 + # Install the openshift examples #openshift_install_examples=true diff --git a/inventory/byo/hosts.origin.example b/inventory/byo/hosts.origin.example index 104c64c23..d3d1e3994 100644 --- a/inventory/byo/hosts.origin.example +++ b/inventory/byo/hosts.origin.example @@ -25,6 +25,23 @@ debug_level=2 # deployment type valid values are origin, online, atomic-enterprise and openshift-enterprise deployment_type=origin +# Specify the generic release of OpenShift to install. This is used mainly just during installation, after which we +# rely on the version running on the first master. Works best for containerized installs where we can usually +# use this to lookup the latest exact version of the container images, which is the tag actually used to configure +# the cluster. For RPM installations we just verify the version detected in your configured repos matches this +# release. +openshift_release=v1.2 + +# Specify an exact container image tag to install or configure. +# WARNING: This value will be used for all hosts in containerized environments, even those that have another version installed. +# This could potentially trigger an upgrade and downtime, so be careful with modifying this value after the cluster is set up. +#openshift_image_tag=v1.2.0 + +# Specify an exact rpm version to install or configure. +# WARNING: This value will be used for all hosts in RPM based environments, even those that have another version installed. +# This could potentially trigger an upgrade and downtime, so be careful with modifying this value after the cluster is set up. +#openshift_image_tag=-1.2.0 + # Install the openshift examples #openshift_install_examples=true diff --git a/inventory/byo/hosts.ose.example b/inventory/byo/hosts.ose.example index ebac28fc6..2514fcc96 100644 --- a/inventory/byo/hosts.ose.example +++ b/inventory/byo/hosts.ose.example @@ -24,6 +24,23 @@ debug_level=2 # deployment type valid values are origin, online, atomic-enterprise, and openshift-enterprise deployment_type=openshift-enterprise +# Specify the generic release of OpenShift to install. This is used mainly just during installation, after which we +# rely on the version running on the first master. Works best for containerized installs where we can usually +# use this to lookup the latest exact version of the container images, which is the tag actually used to configure +# the cluster. For RPM installations we just verify the version detected in your configured repos matches this +# release. +openshift_release=v3.2 + +# Specify an exact container image tag to install or configure. +# WARNING: This value will be used for all hosts in containerized environments, even those that have another version installed. +# This could potentially trigger an upgrade and downtime, so be careful with modifying this value after the cluster is set up. +#openshift_image_tag=v3.2.0.46 + +# Specify an exact rpm version to install or configure. +# WARNING: This value will be used for all hosts in RPM based environments, even those that have another version installed. +# This could potentially trigger an upgrade and downtime, so be careful with modifying this value after the cluster is set up. +#openshift_image_tag=-3.2.0.46 + # Install the openshift examples #openshift_install_examples=true -- cgit v1.2.3 From fb2f9f9d2be747a631e9ab13cb7c7898987d509d Mon Sep 17 00:00:00 2001 From: Devan Goodwin Date: Fri, 24 Jun 2016 10:59:11 -0300 Subject: Allow skipping Docker upgrade during OpenShift upgrade. --- inventory/byo/hosts.aep.example | 7 +++++++ inventory/byo/hosts.origin.example | 7 +++++++ inventory/byo/hosts.ose.example | 7 +++++++ .../openshift-cluster/upgrades/docker/upgrade_check.yml | 13 +++++++++++++ .../openshift-cluster/upgrades/v3_1_to_v3_2/upgrade.yml | 3 +++ 5 files changed, 37 insertions(+) (limited to 'inventory') diff --git a/inventory/byo/hosts.aep.example b/inventory/byo/hosts.aep.example index ffed3c042..0f7998008 100644 --- a/inventory/byo/hosts.aep.example +++ b/inventory/byo/hosts.aep.example @@ -92,6 +92,13 @@ openshift_release=v3.2 # Default value: "--log-driver=json-file --log-opt max-size=50m" #openshift_docker_options="-l warn --ipv6=false" +# Specify exact version of Docker to configure or upgrade to. +# Downgrades are not supported and will error out. Be careful when upgrading docker from < 1.10 to > 1.10. +# docker_version="1.10.3" + +# Skip upgrading Docker during an OpenShift upgrade, leaves the current Docker version alone. +# docker_upgrade=False + # Alternate image format string. If you're not modifying the format string and # only need to inject your own registry you may want to consider # openshift_docker_additional_registries instead diff --git a/inventory/byo/hosts.origin.example b/inventory/byo/hosts.origin.example index d3d1e3994..27dd5a575 100644 --- a/inventory/byo/hosts.origin.example +++ b/inventory/byo/hosts.origin.example @@ -93,6 +93,13 @@ openshift_release=v1.2 # Default value: "--log-driver=json-file --log-opt max-size=50m" #openshift_docker_options="-l warn --ipv6=false" +# Specify exact version of Docker to configure or upgrade to. +# Downgrades are not supported and will error out. Be careful when upgrading docker from < 1.10 to > 1.10. +# docker_version="1.10.3" + +# Skip upgrading Docker during an OpenShift upgrade, leaves the current Docker version alone. +# docker_upgrade=False + # Alternate image format string. If you're not modifying the format string and # only need to inject your own registry you may want to consider # openshift_docker_additional_registries instead diff --git a/inventory/byo/hosts.ose.example b/inventory/byo/hosts.ose.example index 2514fcc96..1831b0bae 100644 --- a/inventory/byo/hosts.ose.example +++ b/inventory/byo/hosts.ose.example @@ -92,6 +92,13 @@ openshift_release=v3.2 # Default value: "--log-driver=json-file --log-opt max-size=50m" #openshift_docker_options="-l warn --ipv6=false" +# Specify exact version of Docker to configure or upgrade to. +# Downgrades are not supported and will error out. Be careful when upgrading docker from < 1.10 to > 1.10. +# docker_version="1.10.3" + +# Skip upgrading Docker during an OpenShift upgrade, leaves the current Docker version alone. +# docker_upgrade=False + # Alternate image format string. If you're not modifying the format string and # only need to inject your own registry you may want to consider # openshift_docker_additional_registries instead diff --git a/playbooks/common/openshift-cluster/upgrades/docker/upgrade_check.yml b/playbooks/common/openshift-cluster/upgrades/docker/upgrade_check.yml index 928913ef3..caf8d1de5 100644 --- a/playbooks/common/openshift-cluster/upgrades/docker/upgrade_check.yml +++ b/playbooks/common/openshift-cluster/upgrades/docker/upgrade_check.yml @@ -1,4 +1,10 @@ --- + +# This snippet determines if docker_upgrade should be set for the host. If it's already +# set via the inventory we will respect it. Otherwise we check if the current version +# is equal to the either the latest, or the requested docker_version, and set +# docker_upgrade accordingly. + - name: Determine available Docker version script: ../../../../common/openshift-cluster/upgrades/files/rpm_versions.sh docker register: g_docker_version_result @@ -26,6 +32,13 @@ # Disable the 1.10 requirement if the user set a specific Docker version when: avail_docker_version.stdout | version_compare('1.10','<') and docker_version is not defined +# We respect docker_upgrade=False in the inventory, but True is the default and +# if set in inventory, we still flip it to False here and only set to true if +# they're not already running the required version. +- set_fact: + docker_upgrade: False + when: docker_upgrade is not defined or docker_upgrade | bool + - name: Flag for upgrade if Docker version does not equal latest set_fact: docker_upgrade: true 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 8eeb652a7..f2e408ad4 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 @@ -80,7 +80,10 @@ delegate_to: "{{ groups.oo_first_master.0 }}" when: inventory_hostname in groups.oo_nodes_to_config + # Only check if docker upgrade is required if docker_upgrade is not + # already set to False. - include: ../docker/upgrade_check.yml + when: docker_upgrade is not defined or docker_upgrade | bool - include: ../docker/upgrade.yml when: docker_upgrade is defined and docker_upgrade | bool -- cgit v1.2.3 From 212faa41ce03f1719598e87fc1453ed8580655ca Mon Sep 17 00:00:00 2001 From: Devan Goodwin Date: Mon, 4 Jul 2016 09:55:25 -0300 Subject: Fix typo in example inventories. --- inventory/byo/hosts.aep.example | 2 +- inventory/byo/hosts.origin.example | 2 +- inventory/byo/hosts.ose.example | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'inventory') diff --git a/inventory/byo/hosts.aep.example b/inventory/byo/hosts.aep.example index a4f730bc0..7f3f7ee50 100644 --- a/inventory/byo/hosts.aep.example +++ b/inventory/byo/hosts.aep.example @@ -39,7 +39,7 @@ openshift_release=v3.2 # Specify an exact rpm version to install or configure. # WARNING: This value will be used for all hosts in RPM based environments, even those that have another version installed. # This could potentially trigger an upgrade and downtime, so be careful with modifying this value after the cluster is set up. -#openshift_image_tag=-3.2.0.46 +#openshift_pkg_version=-3.2.0.46 # Install the openshift examples #openshift_install_examples=true diff --git a/inventory/byo/hosts.origin.example b/inventory/byo/hosts.origin.example index 5b17bbe71..892c015c5 100644 --- a/inventory/byo/hosts.origin.example +++ b/inventory/byo/hosts.origin.example @@ -40,7 +40,7 @@ openshift_release=v1.2 # Specify an exact rpm version to install or configure. # WARNING: This value will be used for all hosts in RPM based environments, even those that have another version installed. # This could potentially trigger an upgrade and downtime, so be careful with modifying this value after the cluster is set up. -#openshift_image_tag=-1.2.0 +#openshift_pkg_version=-1.2.0 # Install the openshift examples #openshift_install_examples=true diff --git a/inventory/byo/hosts.ose.example b/inventory/byo/hosts.ose.example index e74474b58..6e6af3ea7 100644 --- a/inventory/byo/hosts.ose.example +++ b/inventory/byo/hosts.ose.example @@ -39,7 +39,7 @@ openshift_release=v3.2 # Specify an exact rpm version to install or configure. # WARNING: This value will be used for all hosts in RPM based environments, even those that have another version installed. # This could potentially trigger an upgrade and downtime, so be careful with modifying this value after the cluster is set up. -#openshift_image_tag=-3.2.0.46 +#openshift_pkg_version=-3.2.0.46 # Install the openshift examples #openshift_install_examples=true -- cgit v1.2.3