Merge "Add pre-install phase for extras.d plugins"

This commit is contained in:
Jenkins 2014-07-13 19:02:40 +00:00 committed by Gerrit Code Review
commit f29569db7a
2 changed files with 28 additions and 1 deletions

View File

@ -22,9 +22,24 @@ sourced with one or more arguments, the first of which defines the hook phase:
stack: called by stack.sh. There are four possible values for
the second arg to distinguish the phase stack.sh is in:
arg 2: install | post-config | extra | post-extra
arg 2: pre-install | install | post-config | extra
unstack: called by unstack.sh
clean: called by clean.sh. Remember, clean.sh also calls unstack.sh
so that work need not be repeated.
The `stack` phase sub-phases are called from `stack.sh` in the following places:
pre-install - After all system prerequisites have been installed but before any
DevStack-specific services are installed (including database and rpc).
install - After all OpenStack services have been installed and configured
but before any OpenStack services have been started. Changes to OpenStack
service configurations should be done here.
post-config - After OpenStack services have been initialized but still before
they have been started. (This is probably mis-named, think of it as post-init.)
extra - After everything is started.

View File

@ -668,6 +668,18 @@ fi
# Do the ugly hacks for borken packages and distros
$TOP_DIR/tools/fixup_stuff.sh
# Extras Pre-install
# ------------------
# Phase: pre-install
if [[ -d $TOP_DIR/extras.d ]]; then
for i in $TOP_DIR/extras.d/*.sh; do
[[ -r $i ]] && source $i stack pre-install
done
fi
install_rpc_backend
if is_service_enabled $DATABASE_BACKENDS; then