Set DevStack install dir to /usr/local by default

Put everything in /usr/local and allow that to be overridden to
a user-writable dir and not require sudo.

Also set the stx-devstack-update job voting, at this time it only runs
on devstack/* changes.

Change-Id: Ibb27af08e4eaa0ba82d737e1af438a992ec35bfb
Signed-off-by: Dean Troyer <dtroyer@gmail.com>
This commit is contained in:
Dean Troyer 2019-03-07 14:05:33 -06:00
parent 69683e2cdc
commit 8231278f82
2 changed files with 16 additions and 12 deletions

View File

@ -8,8 +8,7 @@
- openstack-tox-pep8
- openstack-tox-linters
- stx-integ-pylint
- stx-devstack-integ:
voting: false
- stx-devstack-integ
gate:
jobs:
- build-openstack-releasenotes

View File

@ -22,8 +22,14 @@ STXINTEG_DIR=${GITDIR[$STX_INTEG_NAME]}
PLATFORM_UTIL_DIR=$STXINTEG_DIR/utilities/platform-util
# STX_INST_DIR should be a non-root-writable place to install build artifacts
STX_INST_DIR=${STX_INST_DIR:-$DEST/usr}
STX_BIN_DIR=$STX_INST_DIR/bin
STX_INST_DIR=${STX_INST_DIR:-/usr/local}
STX_BIN_DIR=${STX_BIN_DIR:-$STX_INST_DIR/bin}
STX_SBIN_DIR=${STX_SBIN_DIR:-$STX_INST_DIR/sbin}
# Set up so we don't use sudo for installs when not necessary
STX_SUDO="sudo"
[[ -w $STX_INST_DIR ]] && STX_SUDO="env"
PYTHON_SITE_DIR=$(python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")
function cleanup_integ {
@ -58,16 +64,15 @@ function install_platform_util {
--single-version-externally-managed
popd
local stx_integ_sbindir=$STX_INST_DIR/sbin
local systemddir=/etc/systemd
sudo install -m 755 -d ${stx_integ_sbindir}
sudo install -m 755 $PLATFORM_UTIL_DIR/scripts/patch-restart-mtce ${stx_integ_sbindir}
sudo install -m 755 $PLATFORM_UTIL_DIR/scripts/patch-restart-processes ${stx_integ_sbindir}
sudo install -m 755 $PLATFORM_UTIL_DIR/scripts/patch-restart-haproxy ${stx_integ_sbindir}
$STX_SUDO install -m 755 -d ${STX_SBIN_DIR}
$STX_SUDO install -m 755 $PLATFORM_UTIL_DIR/scripts/patch-restart-mtce ${STX_SBIN_DIR}
$STX_SUDO install -m 755 $PLATFORM_UTIL_DIR/scripts/patch-restart-processes ${STX_SBIN_DIR}
$STX_SUDO install -m 755 $PLATFORM_UTIL_DIR/scripts/patch-restart-haproxy ${STX_SBIN_DIR}
sudo install -m 755 $PLATFORM_UTIL_DIR/scripts/cgcs_tc_setup.sh ${STX_BIN_DIR}
sudo install -m 755 $PLATFORM_UTIL_DIR/scripts/remotelogging_tc_setup.sh ${STX_BIN_DIR}
sudo install -m 755 $PLATFORM_UTIL_DIR/scripts/connectivity_test ${STX_BIN_DIR}
$STX_SUDO install -m 755 $PLATFORM_UTIL_DIR/scripts/cgcs_tc_setup.sh ${STX_BIN_DIR}
$STX_SUDO install -m 755 $PLATFORM_UTIL_DIR/scripts/remotelogging_tc_setup.sh ${STX_BIN_DIR}
$STX_SUDO install -m 755 $PLATFORM_UTIL_DIR/scripts/connectivity_test ${STX_BIN_DIR}
# sudo install -m 755 $PLATFORM_UTIL_DIR/scripts/opt-platform.mount ${systemddir}/system
# sudo install -m 755 $PLATFORM_UTIL_DIR/scripts/opt-platform.service ${systemddir}/system