Add within-juno dir and within-master symlink
This adds logic to upgrade_project() to call project upgrade scripts from the within-$release directory if performing a sideways upgrade within the same release. A symlink named within-master is added and linked to the current development release to allow sideways migration testing of trunk. When Juno tags are cut and K opens, a from-kilo directoy should be created and this symlink updated. Change-Id: I770075442d05f38515e5dadf24f2c642d14d7845
This commit is contained in:
parent
aabdae97ef
commit
156339e4e8
13
functions
13
functions
@ -1731,10 +1731,17 @@ function upgrade_project {
|
|||||||
|
|
||||||
project=$1
|
project=$1
|
||||||
base_dir=$2
|
base_dir=$2
|
||||||
branch=$3
|
base_branch=$3
|
||||||
|
target_branch=$4
|
||||||
|
|
||||||
upgrade_dir=$(get_release_name_from_branch $branch)
|
if [[ "$base_branch" == "$target_branch" ]]; then
|
||||||
upgrade_file=${base_dir}/"from-"${upgrade_dir}/"upgrade-"${project}
|
direction="within"
|
||||||
|
else
|
||||||
|
direction="from"
|
||||||
|
fi
|
||||||
|
|
||||||
|
upgrade_dir=$(get_release_name_from_branch $base_branch)
|
||||||
|
upgrade_file=${base_dir}/${direction}"-"${upgrade_dir}/"upgrade-"${project}
|
||||||
if [[ -e ${upgrade_file} ]]; then
|
if [[ -e ${upgrade_file} ]]; then
|
||||||
source ${upgrade_file} && configure_${project}_upgrade
|
source ${upgrade_file} && configure_${project}_upgrade
|
||||||
else
|
else
|
||||||
|
@ -58,7 +58,7 @@ source $TARGET_DEVSTACK_DIR/lib/ceilometer
|
|||||||
install_ceilometer
|
install_ceilometer
|
||||||
|
|
||||||
# calls upgrade-ceilometer for specific release
|
# calls upgrade-ceilometer for specific release
|
||||||
upgrade_project ceilometer $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project ceilometer $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
# Migrate the database
|
# Migrate the database
|
||||||
ceilometer-dbsync || die $LINENO "DB sync error"
|
ceilometer-dbsync || die $LINENO "DB sync error"
|
||||||
|
@ -84,7 +84,7 @@ install_cinder
|
|||||||
install_cinderclient
|
install_cinderclient
|
||||||
|
|
||||||
# calls upgrade-cinder for specific release
|
# calls upgrade-cinder for specific release
|
||||||
upgrade_project cinder $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project cinder $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
# Simulate init_cinder()
|
# Simulate init_cinder()
|
||||||
create_cinder_volume_group
|
create_cinder_volume_group
|
||||||
|
@ -24,7 +24,7 @@ set -o xtrace
|
|||||||
# ================
|
# ================
|
||||||
|
|
||||||
# calls upgrade-devstack for specific release
|
# calls upgrade-devstack for specific release
|
||||||
upgrade_project devstack $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project devstack $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
# Preserve accrc files for future usage
|
# Preserve accrc files for future usage
|
||||||
cp -a $BASE_DEVSTACK_DIR/accrc $TARGET_DEVSTACK_DIR/accrc
|
cp -a $BASE_DEVSTACK_DIR/accrc $TARGET_DEVSTACK_DIR/accrc
|
||||||
|
@ -84,7 +84,7 @@ install_glanceclient
|
|||||||
install_glance
|
install_glance
|
||||||
|
|
||||||
# calls upgrade-glance for specific release
|
# calls upgrade-glance for specific release
|
||||||
upgrade_project glance $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project glance $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
# Simulate init_glance()
|
# Simulate init_glance()
|
||||||
create_glance_cache_dir
|
create_glance_cache_dir
|
||||||
|
@ -68,7 +68,7 @@ screen -S $SCREEN_NAME -p horizon -X kill
|
|||||||
install_horizon
|
install_horizon
|
||||||
|
|
||||||
# calls upgrade-horizon for specific release
|
# calls upgrade-horizon for specific release
|
||||||
upgrade_project horizon $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project horizon $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
# Start Horizon
|
# Start Horizon
|
||||||
start_horizon
|
start_horizon
|
||||||
|
@ -107,7 +107,7 @@ install_neutron_third_party
|
|||||||
Q_L3_CONF_FILE=${Q_L3_CONF_FILE:-"$NEUTRON_CONF_DIR/l3_agent.ini"}
|
Q_L3_CONF_FILE=${Q_L3_CONF_FILE:-"$NEUTRON_CONF_DIR/l3_agent.ini"}
|
||||||
Q_FWAAS_CONF_FILE=${Q_FWAAS_CONF_FILE:-"$NEUTRON_CONF_DIR/fwaas_driver.ini"}
|
Q_FWAAS_CONF_FILE=${Q_FWAAS_CONF_FILE:-"$NEUTRON_CONF_DIR/fwaas_driver.ini"}
|
||||||
|
|
||||||
upgrade_project neutron $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project neutron $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
# Get plugin config paths
|
# Get plugin config paths
|
||||||
neutron_plugin_configure_common
|
neutron_plugin_configure_common
|
||||||
|
@ -98,7 +98,7 @@ install_novaclient
|
|||||||
install_nova
|
install_nova
|
||||||
|
|
||||||
# calls upgrade-nova for specific release
|
# calls upgrade-nova for specific release
|
||||||
upgrade_project nova $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project nova $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
# Simulate init_nova()
|
# Simulate init_nova()
|
||||||
create_nova_cache_dir
|
create_nova_cache_dir
|
||||||
|
@ -35,6 +35,6 @@ source $TARGET_DEVSTACK_DIR/lib/oslo
|
|||||||
sudo pip uninstall -y oslo.config
|
sudo pip uninstall -y oslo.config
|
||||||
|
|
||||||
# calls upgrade-oslo for specific release
|
# calls upgrade-oslo for specific release
|
||||||
upgrade_project oslo $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project oslo $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
install_oslo
|
install_oslo
|
||||||
|
@ -82,7 +82,7 @@ install_swift
|
|||||||
install_swiftclient
|
install_swiftclient
|
||||||
|
|
||||||
# calls upgrade-swift for specific release
|
# calls upgrade-swift for specific release
|
||||||
upgrade_project swift $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project swift $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
# Simulate swift_init()
|
# Simulate swift_init()
|
||||||
|
|
||||||
|
@ -65,7 +65,7 @@ source $TARGET_DEVSTACK_DIR/lib/tempest
|
|||||||
install_tempest
|
install_tempest
|
||||||
|
|
||||||
# calls upgrade-tempest for specific release
|
# calls upgrade-tempest for specific release
|
||||||
upgrade_project tempest $GRENADE_DIR $BASE_DEVSTACK_BRANCH
|
upgrade_project tempest $GRENADE_DIR $BASE_DEVSTACK_BRANCH $TARGET_DEVSTACK_BRANCH
|
||||||
|
|
||||||
OS_USERNAME=admin
|
OS_USERNAME=admin
|
||||||
if $(source $BASE_DEVSTACK_DIR/stackrc; is_service_enabled neutron); then
|
if $(source $BASE_DEVSTACK_DIR/stackrc; is_service_enabled neutron); then
|
||||||
|
10
within-juno/README.rst
Normal file
10
within-juno/README.rst
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
===========================================
|
||||||
|
Juno to Juno specific sideways upgrade scripts
|
||||||
|
===========================================
|
||||||
|
This directory can house service scripts for upgrading within the Juno
|
||||||
|
release.
|
||||||
|
|
||||||
|
To do this add ``upgrade-$servicename`` script to this directory and
|
||||||
|
include a ``configure_$servicename_upgrade`` function in the file. All
|
||||||
|
services that don't have a specific upgrade script will just use the
|
||||||
|
generic one, which performs a db-sync and installs the updated code.
|
1
within-master
Symbolic link
1
within-master
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
within-juno/
|
Loading…
x
Reference in New Issue
Block a user