Skip to content

Commit 5c1f291

Browse files
Zuulopenstack-gerrit
authored andcommitted
Merge "Use playbooks from collection for run-upgrade.sh"
2 parents 372f9fe + 4045e33 commit 5c1f291

1 file changed

Lines changed: 18 additions & 20 deletions

File tree

scripts/run-upgrade.sh

Lines changed: 18 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -190,26 +190,24 @@ function main {
190190

191191
bootstrap_ansible
192192

193-
pushd ${MAIN_PATH}/playbooks
194-
RUN_TASKS+=("${SCRIPTS_PATH}/upgrade-utilities/deploy-config-changes.yml")
195-
# we don't want to trigger container restarts for galera and rabbit
196-
# but as there will be no hosts available for metal deployments,
197-
# as a fallback option we just run setup-hosts.yml without any arguments
198-
RUN_TASKS+=("setup-hosts.yml --limit '!galera_all:!rabbitmq_all' -e package_state=latest && \
199-
openstack-ansible setup-hosts.yml -e 'lxc_container_allow_restarts=false' --limit 'galera_all:rabbitmq_all' || \
200-
openstack-ansible setup-hosts.yml -e package_state=latest")
201-
# upgrade infrastructure
202-
RUN_TASKS+=("setup-infrastructure.yml -e 'galera_upgrade=true' -e 'rabbitmq_upgrade=true' -e package_state=latest")
203-
# explicitly perform controlled galera cluster restart with new lxc config
204-
RUN_TASKS+=("${SCRIPTS_PATH}/upgrade-utilities/galera-cluster-rolling-restart.yml")
205-
# upgrade openstack
206-
RUN_TASKS+=("setup-openstack.yml -e package_state=latest")
207-
# Run the tasks in order
208-
for item in ${!RUN_TASKS[@]}; do
209-
echo "### NOW RUNNING: ${RUN_TASKS[$item]}"
210-
run_lock $item "${RUN_TASKS[$item]}"
211-
done
212-
popd
193+
RUN_TASKS+=("openstack.osa.upgrade.deploy_config_changes")
194+
# we don't want to trigger container restarts for galera and rabbit
195+
# but as there will be no hosts available for metal deployments,
196+
# as a fallback option we just run setup_hosts.yml without any arguments
197+
RUN_TASKS+=("openstack.osa.setup_hosts --limit '!galera_all:!rabbitmq_all' -e package_state=latest && \
198+
openstack-ansible openstack.osa.setup_hosts -e 'lxc_container_allow_restarts=false' --limit 'galera_all:rabbitmq_all' || \
199+
openstack-ansible openstack.osa.setup_hosts -e package_state=latest")
200+
# upgrade infrastructure
201+
RUN_TASKS+=("openstack.osa.setup_infrastructure -e 'galera_upgrade=true' -e 'rabbitmq_upgrade=true' -e package_state=latest")
202+
# explicitly perform controlled galera cluster restart with new lxc config
203+
RUN_TASKS+=("openstack.osa.tools.galera_cluster_rolling_restart")
204+
# upgrade openstack
205+
RUN_TASKS+=("openstack.osa.setup_openstack -e package_state=latest")
206+
# Run the tasks in order
207+
for item in ${!RUN_TASKS[@]}; do
208+
echo "### NOW RUNNING: ${RUN_TASKS[$item]}"
209+
run_lock $item "${RUN_TASKS[$item]}"
210+
done
213211
}
214212

215213
main

0 commit comments

Comments
 (0)