Radosław Piliszek 2725ed9d84 Emergency fixes to pass CI
1) makes bifrost unbuildable as it evolves rapidly at the moment
2) makes neutron bootstrap/upgrade only the core service [1]

1) will be reverted
2) will be made more flexible

[1] https://bugs.launchpad.net/bgpvpn/+bug/1894056

Change-Id: I1eefcfceded985b5f61ee8d796f9d8994c9ee97c
2020-09-05 17:42:22 +00:00

37 lines
1.3 KiB
Bash

#!/bin/bash
# Bootstrap and exit if KOLLA_BOOTSTRAP variable is set. This catches all cases
# of the KOLLA_BOOTSTRAP variable being set, including empty.
if [[ "${!KOLLA_BOOTSTRAP[@]}" ]]; then
# if [[ "${!NEUTRON_BOOTSTRAP_SERVICES[@]}" ]]; then
# for service in ${NEUTRON_BOOTSTRAP_SERVICES}; do
# neutron-db-manage --subproject $service upgrade head
# done
# fi
# FIXME(yoctozepto): dirty hack to pass CI (uncomment the above when done)
neutron-db-manage --subproject neutron upgrade head
exit 0
fi
# Migrate database and exit if KOLLA_UPGRADE variable is set. This catches all cases
# of the KOLLA_UPGRADE variable being set, including empty.
if [[ "${!KOLLA_UPGRADE[@]}" ]]; then
if [[ "${!NEUTRON_DB_EXPAND[@]}" ]]; then
DB_ACTION="--expand"
echo "Expanding database"
fi
if [[ "${!NEUTRON_DB_CONTRACT[@]}" ]]; then
DB_ACTION="--contract"
echo "Contracting database"
fi
# if [[ "${!NEUTRON_ROLLING_UPGRADE_SERVICES[@]}" ]]; then
# for service in ${NEUTRON_ROLLING_UPGRADE_SERVICES}; do
# neutron-db-manage --subproject $service upgrade $DB_ACTION
# done
# fi
# FIXME(yoctozepto): dirty hack to pass CI (uncomment the above when done)
neutron-db-manage --subproject neutron upgrade $DB_ACTION
exit 0
fi