redeploy should be done in the proper folder

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
This commit is contained in:
Jean-Philippe Evrard 2017-08-30 13:59:30 +00:00
parent 3d85e5a5fd
commit b77287b87f
6 changed files with 8 additions and 18 deletions

View File

@ -26,7 +26,10 @@ export MITAKA_RELEASE="${MITAKA_RELEASE:-mitaka-eol}"
export NEWTON_RELEASE="${NEWTON_RELEASE:-14.2.7}"
## Environment Vars ------------------------------------------------------------------
# main path changes with releases leaping
export MAIN_PATH="${MAIN_PATH:-/opt/openstack-ansible}"
# this is the final folder for redeploy.
export REDEPLOY_OA_FOLDER="${REDEPLOY_OA_FOLDER:-/opt/openstack-ansible}"
export SYSTEM_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )"/../ && pwd )"
export UPGRADE_UTILS="${UPGRADE_UTILS:-${SYSTEM_PATH}/upgrade-utilities}"

View File

@ -14,9 +14,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# NOTICE: To run this in an automated fashion run the script via
# root@HOSTNAME:/opt/openstack-ansible# echo "YES" | bash scripts/run-upgrade.sh
## Shell Opts ----------------------------------------------------------------
set -e -u
@ -32,7 +29,9 @@ if [[ ! -f "/opt/leap42/openstack-ansible-poweroff.leap" ]]; then
fi
RUN_TASKS=()
RUN_TASKS+=("${UPGRADE_UTILS}/power-down.yml")
run_items "/opt/openstack-ansible"
# This run_items doesn't care about which folder it runs in, because just
# one task is used, and it's not in the folder
run_items "${REDEPLOY_OA_FOLDER}"
tag_leap_success "poweroff"
fi

View File

@ -14,9 +14,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# NOTICE: To run this in an automated fashion run the script via
# root@HOSTNAME:/opt/openstack-ansible# echo "YES" | bash scripts/run-upgrade.sh
## Shell Opts ----------------------------------------------------------------
set -e -u

View File

@ -14,9 +14,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# NOTICE: To run this in an automated fashion run the script via
# root@HOSTNAME:/opt/openstack-ansible# echo "YES" | bash scripts/run-upgrade.sh
## Shell Opts ----------------------------------------------------------------
set -e -u
@ -142,5 +139,5 @@ if [[ ${REDEPLOY_EXTRA_SCRIPT:-} ]]; then
notice "Running extra script before re-deploy"
source ${REDEPLOY_EXTRA_SCRIPT}
fi
run_items "/opt/openstack-ansible"
run_items "${REDEPLOY_OA_FOLDER}"
### Run the redeploy tasks

View File

@ -14,9 +14,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# NOTICE: To run this in an automated fashion run the script via
# root@HOSTNAME:/opt/openstack-ansible# echo "YES" | bash scripts/run-upgrade.sh
## Shell Opts ----------------------------------------------------------------
set -e -u

View File

@ -14,9 +14,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# NOTICE: To run this in an automated fashion run the script via
# root@HOSTNAME:/opt/openstack-ansible# echo "YES" | bash scripts/run-upgrade.sh
## Shell Opts ----------------------------------------------------------------
set -e -u
@ -130,6 +127,6 @@ if [[ ! -f "/opt/leap42/openstack-ansible-upgrade-hostupgrade.leap" ]]; then
RUN_TASKS=()
RUN_TASKS+=("${UPGRADE_UTILS}/pip-conf-purge.yml")
RUN_TASKS+=("openstack-hosts-setup.yml")
run_items "/opt/openstack-ansible"
run_items "${REDEPLOY_OA_FOLDER}"
tag_leap_success "upgrade-hostupgrade"
fi