diff options
author | Ruby Loo <rloo@verizonmedia.com> | 2019-02-12 22:37:36 +0000 |
---|---|---|
committer | Ruby Loo <rloo@verizonmedia.com> | 2019-02-20 17:24:42 +0000 |
commit | 33383c9c73955f4a41b0ad31f80dcee1f797773d (patch) | |
tree | 9966c572edbd0272068655170c0e6a63b6e76ab0 /devstack | |
parent | 506cb121609b73a9174bf2676c32c8ac7421a441 (diff) | |
download | ironic-33383c9c73955f4a41b0ad31f80dcee1f797773d.tar.gz |
Add check for object versions
Adds a check for compatibility of the object versions (in the DB)
with the release of ironic. This check is used by the
'ironic-status upgrade check' command.
The ironic-status command is added to devstack and grenade (when
upgrading).
Change-Id: I2043dc01856106d50356637db327a2817db90366
Story: 2004990
Task: 29459
Diffstat (limited to 'devstack')
-rw-r--r-- | devstack/lib/ironic | 4 | ||||
-rwxr-xr-x | devstack/upgrade/upgrade.sh | 5 |
2 files changed, 9 insertions, 0 deletions
diff --git a/devstack/lib/ironic b/devstack/lib/ironic index e10ef7e71..46250f125 100644 --- a/devstack/lib/ironic +++ b/devstack/lib/ironic @@ -1417,6 +1417,10 @@ function init_ironic { $IRONIC_BIN_DIR/ironic-dbsync --config-file=$IRONIC_CONF_FILE fi create_ironic_cache_dir + + # NOTE(rloo): We're not upgrading but want to make sure this command works, + # even though we're not parsing the output of this command. + $IRONIC_BIN_DIR/ironic-status upgrade check } # _ironic_bm_vm_names() - Generates list of names for baremetal VMs. diff --git a/devstack/upgrade/upgrade.sh b/devstack/upgrade/upgrade.sh index f4cb426e1..eee38cac7 100755 --- a/devstack/upgrade/upgrade.sh +++ b/devstack/upgrade/upgrade.sh @@ -71,6 +71,11 @@ stack_install_service ironic # calls upgrade-ironic for specific release upgrade_project ironic $RUN_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH +# NOTE(rloo): make sure it is OK to do an upgrade. Except that we aren't +# parsing/checking the output of this command because the output could change +# based on the checks it makes. +$IRONIC_BIN_DIR/ironic-status upgrade check + $IRONIC_BIN_DIR/ironic-dbsync --config-file=$IRONIC_CONF_FILE # NOTE(vsaienko) pin_release only on multinode job, for cold upgrade (single node) |