diff --git a/ci/test/magento/deploy_brancher.php b/ci/test/magento/deploy_brancher.php index 65581a1..947bf1b 100644 --- a/ci/test/magento/deploy_brancher.php +++ b/ci/test/magento/deploy_brancher.php @@ -18,6 +18,7 @@ ]); $productionStage = $configuration->addStage('test', 'banaan.store'); -$productionStage->addBrancherServer('hndeployintegr8'); +$productionStage->addBrancherServer('hndeployintegr8') + ->setLabels(['gitref='.\getenv('GITHUB_SHA') ?: 'unknown']); return $configuration; diff --git a/ci/test/run-brancher.sh b/ci/test/run-brancher.sh index a0d09fe..35e1437 100755 --- a/ci/test/run-brancher.sh +++ b/ci/test/run-brancher.sh @@ -72,7 +72,11 @@ $DP jq .hostnames[0] deployment-report.json -r -e $DP jq .brancher_hypernodes[0] deployment-report.json -r -e # Remove deployment report to make sure we can clean up using hnapi and labels matching +BRANCHER_INSTANCE=$($DP jq .brancher_hypernodes[0] deployment-report.json -r -e) $DP rm -f deployment-report.json # cleanup data -$DP hypernode-deploy cleanup test -vvv +$DP hypernode-deploy cleanup test -vvv | tee cleanup.log + +# Run tests on cleanup +grep "Stopping brancher Hypernode ${BRANCHER_INSTANCE}..." cleanup.log