From 297a50ac86e597cb31c7f4347925ad0e5984960f Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Wed, 20 Jun 2018 11:08:54 +0200 Subject: [PATCH] Convert to openSUSE Leap 15.0 platform testing Leap 15.0 has been released May 25th, 2018 (see https://en.opensuse.org/Portal:15.0 ) and we'd like to transition devstack against it and remove Leap 42.3 from the testing matrix. Leap 15.0 is newer than Leap 42.3 as the numbering schema of openSUSE was changed. Co-Authored-By: Antonio Ojea Change-Id: I078f9a2580160c564c33e575008516f5e92239d6 --- .zuul.yaml | 12 ++++++------ functions-common | 8 +++++--- lib/databases/mysql | 2 +- stack.sh | 3 ++- 4 files changed, 14 insertions(+), 11 deletions(-) diff --git a/.zuul.yaml b/.zuul.yaml index 9d73bede54..87b8049403 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -19,10 +19,10 @@ - controller - nodeset: - name: devstack-single-node-opensuse-423 + name: devstack-single-node-opensuse-150 nodes: - name: controller - label: opensuse-423 + label: opensuse-150 groups: - name: tempest nodes: @@ -395,10 +395,10 @@ voting: false - job: - name: devstack-platform-opensuse-423 + name: devstack-platform-opensuse-150 parent: tempest-full - description: openSUSE 43.2 platform test - nodeset: devstack-single-node-opensuse-423 + description: openSUSE 15.0 platform test + nodeset: devstack-single-node-opensuse-150 voting: false - job: @@ -487,7 +487,7 @@ jobs: - devstack - devstack-platform-centos-7 - - devstack-platform-opensuse-423 + - devstack-platform-opensuse-150 - devstack-platform-opensuse-tumbleweed - devstack-platform-fedora-latest - devstack-multinode diff --git a/functions-common b/functions-common index fae936a3d0..fa571aecfd 100644 --- a/functions-common +++ b/functions-common @@ -374,8 +374,10 @@ function GetDistro { elif [[ "$os_VENDOR" =~ (openSUSE) ]]; then DISTRO="opensuse-$os_RELEASE" # Tumbleweed uses "n/a" as a codename, and the release is a datestring - # like 20180218, so not very useful. - [ "$os_CODENAME" = "n/a" ] && DISTRO="opensuse-tumbleweed" + # like 20180218, so not very useful. Leap however uses a release + # with a "dot", so for example 15.0 + [ "$os_CODENAME" = "n/a" -a "$os_RELEASE" = "${os_RELEASE/\./}" ] && \ + DISTRO="opensuse-tumbleweed" elif [[ "$os_VENDOR" =~ (SUSE LINUX) ]]; then # just use major release DISTRO="sle${os_RELEASE%.*}" @@ -1376,7 +1378,7 @@ function zypper_install { [[ "$(id -u)" = "0" ]] && sudo="env" $sudo http_proxy="${http_proxy:-}" https_proxy="${https_proxy:-}" \ no_proxy="${no_proxy:-}" \ - zypper --non-interactive install --auto-agree-with-licenses "$@" + zypper --non-interactive install --auto-agree-with-licenses --no-recommends "$@" } function write_user_unit_file { diff --git a/lib/databases/mysql b/lib/databases/mysql index cf61056389..ac0c083c91 100644 --- a/lib/databases/mysql +++ b/lib/databases/mysql @@ -16,7 +16,7 @@ MYSQL_DRIVER=${MYSQL_DRIVER:-PyMySQL} register_database mysql MYSQL_SERVICE_NAME=mysql -if is_fedora && ! is_oraclelinux; then +if is_suse || is_fedora && ! is_oraclelinux; then MYSQL_SERVICE_NAME=mariadb fi diff --git a/stack.sh b/stack.sh index 56e00bfb67..be3c4be147 100755 --- a/stack.sh +++ b/stack.sh @@ -221,7 +221,7 @@ write_devstack_version # Warn users who aren't on an explicitly supported distro, but allow them to # override check and attempt installation with ``FORCE=yes ./stack`` -if [[ ! ${DISTRO} =~ (xenial|artful|bionic|stretch|jessie|f27|f28|opensuse-42.3|opensuse-tumbleweed|rhel7) ]]; then +if [[ ! ${DISTRO} =~ (xenial|artful|bionic|stretch|jessie|f27|f28|opensuse-42.3|opensuse-15.0|opensuse-tumbleweed|rhel7) ]]; then echo "WARNING: this script has not been tested on $DISTRO" if [[ "$FORCE" != "yes" ]]; then die $LINENO "If you wish to run this script anyway run with FORCE=yes" @@ -1137,6 +1137,7 @@ if is_service_enabled neutron; then echo_summary "Configuring Neutron" configure_neutron + # Run init_neutron only on the node hosting the Neutron API server if is_service_enabled $DATABASE_BACKENDS && is_service_enabled neutron; then init_neutron