diff --git a/.drone.yml b/.drone.yml index a641707..81ebe63 100644 --- a/.drone.yml +++ b/.drone.yml @@ -1,7 +1,6 @@ --- pipeline: build: - privileged: true image: rancher/dind:v0.6.0 commands: - ./scripts/ci diff --git a/scripts/test b/scripts/test index 77a71aa..864fbd7 100755 --- a/scripts/test +++ b/scripts/test @@ -6,6 +6,10 @@ cd $(dirname $0)/.. trap "rm -rf /scratch/*" exit GIT_BRANCH=$(git rev-parse --abbrev-ref HEAD) +if [ -n "${DRONE_BRANCH}" ]; then + git checkout -b ${DRONE_BRANCH} + GIT_BRANCH=${DRONE_BRANCH} +fi if [ "$GIT_BRANCH" != "master" ]; then sed -i "s#master#$GIT_BRANCH#" ./scripts/repo.json