An operator might want to ensure Swift is available during
an upgrade and manually upgrade Swift on completion of the
maintenance.
The operator would need to set these vars before operation:
export SKIP_SWIFT_UPGRADE=yes
export CONTAINERS_TO_DESTROY=add_!swift_all_exclusion
This would prevent the swift containers from being torn
down during the upgrade and would skip all Swift upgrade
operations.
Change-Id: Ibf40499750751dd9f41e447b7b90bb77f592cc14
Avoids using setuptools 34.x as using it can hit this bug
when packages are being upgraded:
https://github.com/pypa/setuptools/issues/951
Pinning to setuptools==33.1.1 also aligns to the
global-requirement-pins.txt in newton-eol
Change-Id: Ib33b828751c5a36d61448d148c5941beb6827c73
Adds a few tweaks to get Mitaka to function as a
leapfrog source.
- Adds Mitaka as option
- Adjusts detection to include eol branches
- Creates file if user_variables.yml doesn't exist
- Checks if osa_secrets_file_name exists
Change-Id: Id0bce1441456bc545deca67710004b750901e81b
Removes the BOOTSTRAP_ANSIBLE_FOLDER variable because
the assumption was made that Ansible would always be
bootstrapped from /opt/openstack-ansible and setting
this would cause a noop when Ansible was bootstrapped.
Change-Id: I284ad62b6f14cc334ae949946e839a1e8ec6a1d8
Existing code assumes starting point of KILO_RELEASE.
This change allows other releases to be the starting
point before the migrations occur.
Change-Id: Idb7d2981b37e653c9e92a9e41e4bf54b17aef1f5
If you run the script manually and export the target release to another tag, it
might generate a broken link, this ensure the target exists.
Change-Id: Ia18bd7796f5f48c42ad9c23e917ddb37aa8103b3
Previously the operator could choose to leap from old
code once the code to leap to had been deployed. This
would cause things to break as it would attempt to
run the older version code on top of the newly deployed
leaped code.
This identifies those conditions, alerts the operator
and calls the resume_incompete_leap instead of asking
the operator to input the release to upgrade from
again.
Change-Id: I928bf7e6db88d46617af800692e9b76a6bcc1ba8
The leap tooling was attempting to run `set_upgrade_vars` at point where
specific upgrade variables were already needed. Within this change that
function call is moved up a few lines so that it has the chance to set
the required values. Additionally the option to pre-define the variable
CODE_UPGRADE_FROM has been added giving the deployer the option to set
this variable before a leap upgrade is run.
Change-Id: I2c780eb46dd57e680fc8681824de2fe913824fd9
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
Leapfrogs currently only work with Juno/Kilo
releases as certain parts are hard coded.
This patch adds support for handling
multiple releases and attempts to remove some
duplicate code with loops.
Also adds a UPGRADES_TO_TODOLIST variable check on
migration.sh and upgrade.sh to ensure the list of
releases to be ugpraded to are set if the commands
are ran individually.
Change-Id: Ia56f073863533d4b6fa58b78b59b5086c7f9a331
Previously if a redeploy failed during the process, if
you attempted to start it over, it would reprompt for the
version you were attempting to upgrade. At this point in
process, you are already on the latest version of the code,
so putting the original code version would actually break
the leap. This attempts to detect if a redeploy started
but didn't complete and asks the user if they would like
to reattempt the redeploy.
Change-Id: I7c2f734edc4ec3186be3d24a60ee41b43269d07b
In case the scripts are run independently and not via run-stages.sh
some vars are not set for script execution and the deployer need to
export a new env var.
Change-Id: I4f24478d92563f5c00fefce269120f1b908aedcd
run_ansible wrapper should work in the latest checkout of OA,
which should be in a REDEPLOY folder instead of just
a static "/opt/openstack-ansible"
Change-Id: I4d20fd7480f2f38e55d3f081c0c0f11726458583
Some providers may have a different bootstrapping script,
and probably want to use their own instead of always
bootstrapping the OSA one for the leap.
We should be able to give a script as env var, and use
that script for installing an ansible that works for leapfrog.
Change-Id: I034d3dace52ae092e04d4573c6299b464153084d
Previous change forgot to remove the NOT, this fixes that. We should
install libmariadbclient-dev if libmariadbclient is detected, not
libmysqlclient-dev.
Change-Id: Id261a2b0d3574ed8995c969320000a742e60f4da
Bootstrap ansible should already do the needful, and we
shouldn't help him bootstrap, because we already did
pre-flight checks that are technically sufficient for it to
run.
Change-Id: I910eb4f0bd4d3eeef52885fcf30aa865634fb105
more headers were needed, also, revert the kilo release change.
eol-kilo has swift in upper-constraints, which causes problems for venv
building, it was removed from future releases for this exactly this
reason.
Change-Id: I1f8c8ea4681ab63dd67851235f405d1cbd478eae
The comment on the bug in setuptools was fixed a while ago upstream and
evrardjp also mentioned that comment could be removed. Branches other
than newton have an EOL release, so change to use those.
Change-Id: I80cf1fc929e86c3498760ad4b342964c7f82ea5f
RPC is using r11 and 11 for kilo, same for upper branches.
We should be more lenient to the version allowed, whether it's
starting with a r or not, as long as the major version is the
same number.
Change-Id: I42053681fdc5e0b2c16060d8a51b4a620569f38c
In cases where the deployment node is seperated from the infrastructure
node, the openstack-release file discovery logic might calculate the
wrong release since the /etc/openstack-release file does not get generated
on the deployment node.
This commit adds logic to pull down the /etc/openstack-release file from
the infrastucture node to the deployment node. This way, the release discovery
logic will properly assess the openstack release even in situations where the
deployment node is isolated from the infra node.
If the openstack-release file is not found, an attempt to retrieve the
rpc-release file is made.
A conditional is added to check if the rpc-release file exist in the
environment. If it does, and there is no openstack-release file, then
the deployment version is set to Juno.
Co-Authored-By: git-harry <git-harry@live.co.uk>
Change-Id: I6136609ef11be7b98ddcfc7589dd17cf1e98c362
`libmysqlclient-dev` is missing, when performing a Kilo to Newton upgrade
on a multi-node AIO, causing `mysql-python` to fail to install. This
change ensures it is present.
Change-Id: Id418929b1713357bea183c50b64219f175aee9bc
This change is necessary to ensure that all the required PIP packages
are installed. Without this change the code assumes that if the version
of `pip` in okay then all the required packages are already installed.
Change-Id: I16a4eaf24e346411a7f0890d69939f666ecc6be3
Make sure the liberasurecode-dev is installable when needed, in order
to build the venvs for swift.
No distinction is done anymore for backports/anything else like UCA.
Change-Id: I552b77eeb05469b815592da1dd7fab45124ffe89
While we could do better by using other mechanisms than shell
scripts, this commit sticks to the current method of doing (having
marker files), to mark steps that were missing a marker.
On top of it, you couldn't resume from a leapfrog that's started
from a shell script, because the readlink failed.
Change-Id: I73f09bb8214741772545c73fac5e5fdb5698c52e
Instead of relying on "echo YES| " in gating, we should re-use
an environment variable that bypasses the user validation.
This commit also adds logging of the extra step that was added
previously.
Change-Id: If5e986daa6404470d9d260032a24eb8cc17aa161
This change:
- discovers the current running version to know what
to leap from, because we can't assume Juno only.
At the same time it introduces a human verification
of the source branch.
- removes the useless "-v" of the runs that produced
an undesirable output, making the interface less
"user friendly".
Change-Id: I04e4780bf5f58638addbd992eab7152f288532ae
Co-Authored-By: Jean-Philippe Evrard <jean-philippe@evrard.me>
When building a venv for leap upgrades, checkout the applicable
requirements repo SHA and apply its upper-constraints file. If
packages within the venv are installed unconstrained, a project's
database migration scripts may fail.
Also remove tempest from being built within the venv.
Change-Id: Ic7e9aaa2d445bfe22c0f707a00a867cc8e84a38d
Precreated bundled venvs for OpenStack-Ansible have been created,
update the default VENV_URL with the path to them. Also fix the wget
command used to download them so that it returns a 0 on success and
deletes a failed download allowing the local build function to continue
on.
Change-Id: Ic4ae115384015dd7159da4e5850452bb5db181be
Perform a git branch checkout on cloned OSA repo directories when the
ignore-changes.marker file does not exist.
Change-Id: Ib062198f54e399d644e13c7aea7582e0ad6e1976
- Check for existence of the configuration directory
(rpc_deploy/openstack_deploy) since only one should exist, dependent
on the current stage of the upgrade
- Correct the path to upgrade-requirements.txt
- Use pip to install requirements found in upgrade-requirements.txt
to avoid a 'double requirement given' error when installing pip
Change-Id: If39826c26eb948b91f14e7e27d0a5d0740c8349c
This change adds upgrade tooling that will take a Juno based
OpenStack-Ansible cloud and upgrade it to Newton. The tooling
will run a deployment through all of the needed steps upgrading
the environment and skipping all of the OpenStack releases in
between.
**This tooling should be considered experimental at this time**
Change-Id: I1880794717b9e47786ae255ea1afa57d805cde8e
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>