From 9ab23ac448d629a362bdba142b685217b2103f07 Mon Sep 17 00:00:00 2001 From: Micah Anderson Date: Thu, 20 Apr 2017 14:59:51 -0400 Subject: switch to using CI_ENVIRONMENT_NAME and defaulting to the basic deployment --- tests/platform-ci/ci-build.sh | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'tests/platform-ci/ci-build.sh') diff --git a/tests/platform-ci/ci-build.sh b/tests/platform-ci/ci-build.sh index 869e7517..a9731fca 100755 --- a/tests/platform-ci/ci-build.sh +++ b/tests/platform-ci/ci-build.sh @@ -81,8 +81,23 @@ set +x /bin/chmod 600 ~/.ssh/id_rsa /bin/cp "${ROOTDIR}/provider/users/gitlab-runner/gitlab-runner_ssh.pub" ~/.ssh/id_rsa.pub -case "$CI_BUILD_STAGE" in - build) +case "$CI_ENVIRONMENT_NAME" in + latest) + TAG='latest' + echo "Cloning ibex provider..." + git clone -q --depth 1 ssh://gitolite@leap.se/ibex + cd ibex + git rev-parse HEAD + echo -n "Operating in the ibex directory: " + pwd + echo "Listing current node information..." + LEAP_CMD list + echo "Attempting a deploy..." + deploy + echo "Attempting to run tests..." + test + ;; + *) # create node(s) with unique id so we can run tests in parallel NAME="citest${CI_BUILD_ID}" # when using gitlab-runner locally, CI_BUILD_ID is always 1 which @@ -101,19 +116,4 @@ case "$CI_BUILD_STAGE" in LEAP_CMD vm rm "${TAG}" [ -f "nodes/${NAME}.json" ] && /bin/rm "nodes/${NAME}.json" ;; - latest) - TAG='latest' - echo "Cloning ibex provider..." - git clone -q --depth 1 ssh://gitolite@leap.se/ibex - cd ibex - git rev-parse HEAD - echo -n "Operating in the ibex directory: " - pwd - echo "Listing current node information..." - LEAP_CMD list - echo "Attempting a deploy..." - deploy - echo "Attempting to run tests..." - test - ;; esac -- cgit v1.2.3