From 2c020be47031052406e53e4027b32d972fcf5e72 Mon Sep 17 00:00:00 2001 From: Teruaki Ishizaki Date: Fri, 20 Jan 2017 18:59:50 +0900 Subject: [PATCH] Changed to do CI on Xenial platform. Change-Id: I4b59a0aa6e457aa8dc435f79d7e788c7ed432dc1 --- devstack/plugin.sh | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/devstack/plugin.sh b/devstack/plugin.sh index 299c82c..2d0861b 100644 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -35,8 +35,8 @@ SHEEPDOG_LOOPBACK_DISK_SIZE=${SHEEPDOG_LOOPBACK_DISK_SIZE:-$SHEEPDOG_LOOPBACK_DI # check_os_support_sheepdog() - Check if the operating system provides a decent version of Sheepdog function check_os_support_sheepdog { - if [[ ! ${DISTRO} =~ (trusty) ]]; then - echo "WARNING: your distro $DISTRO does not provide (at least) the Firefly release. Please use Ubuntu Trusty" + if [[ ! ${DISTRO} =~ (trusty) && ! ${DISTRO} =~ (xenial) ]]; then + echo "WARNING: your distro $DISTRO does not provide (at least) the Firefly release. Please use Ubuntu Trusty or Xenial." if [[ "$FORCE_SHEEPDOG_INSTALL" != "yes" ]]; then die $LINENO "If you wish to install Sheepdog on this distribution anyway run with FORCE_SHEEPDOG_INSTALL=yes" fi @@ -73,18 +73,25 @@ function configure_sheepdog { # install_sheepdog() - Collect source and prepare function install_sheepdog { - if [[ ${os_CODENAME} =~ trusty ]]; then + if [[ ${os_CODENAME} =~ trusty || ${os_CODENAME} =~ xenial ]]; then NO_UPDATE_REPOS=False install_package sheepdog install_package xfsprogs else - exit_distro_not_supported "Sheepdog since your distro doesn't provide (at least) the Firefly release. Please use Ubuntu Trusty." + exit_distro_not_supported "Sheepdog since your distro doesn't provide (at least) the Firefly release. Please use Ubuntu Trusty or Xenial." fi } # start_sheepdog() - Start running processes, including screen function start_sheepdog { - run_process sheepdog "sheep -f -o -l 7 -c local -n ${SHEEPDOG_DATA_DIR}" + if [[ ${DISTRO} =~ (trusty) ]]; then + run_process sheepdog "sheep -f -o -l 7 -c local -n ${SHEEPDOG_DATA_DIR}" + elif [[ ${DISTRO} =~ (xenial) ]]; then + run_process sheepdog "sheep -l dst=stdout,level=debug,format=server -c local -n ${SHEEPDOG_DATA_DIR}" + else + exit_distro_not_supported "Sheepdog since your distro doesn't provide (at least) the Firefly release. Please use Ubuntu Trusty or Xenial." + fi + sleep 3 dog cluster format -c 1