From 65254fe473ff1b37eb7482099b6858497aeff3cf Mon Sep 17 00:00:00 2001 From: Pankaj Garg Date: Tue, 13 Nov 2018 21:14:16 +0000 Subject: [PATCH] Change testnet automation to use TAR instead of snap --- ci/publish-solana-tar.sh | 34 ++++++++++++++++++++-------------- ci/solana-testnet.yml | 5 ----- ci/testnet-automation.sh | 6 +++--- 3 files changed, 23 insertions(+), 22 deletions(-) diff --git a/ci/publish-solana-tar.sh b/ci/publish-solana-tar.sh index 749bae10155219..fbc070827f48c9 100755 --- a/ci/publish-solana-tar.sh +++ b/ci/publish-solana-tar.sh @@ -55,21 +55,27 @@ echo --- Creating tarball tar jvcf solana-release.tar.bz2 solana-release/ ) -echo --- AWS S3 Store -if [[ -z $DRYRUN ]]; then - ( - set -x - if [[ ! -r s3cmd-2.0.1/s3cmd ]]; then - rm -rf s3cmd-2.0.1.tar.gz s3cmd-2.0.1 - $DRYRUN wget https://github.com/s3tools/s3cmd/releases/download/v2.0.1/s3cmd-2.0.1.tar.gz - $DRYRUN tar zxf s3cmd-2.0.1.tar.gz - fi +echo --- Saving build artifacts +source ci/upload_ci_artifact.sh +upload_ci_artifact solana-release.tar.bz2 - $DRYRUN python ./s3cmd-2.0.1/s3cmd --acl-public put solana-release.tar.bz2 \ - s3://solana-release/"$CHANNEL_OR_TAG"/solana-release.tar.bz2 - ) -else - echo Skipped due to DRYRUN +if [[ -z $DO_NOT_PUBLISH_TAR ]]; then + echo --- AWS S3 Store + if [[ -z $DRYRUN ]]; then + ( + set -x + if [[ ! -r s3cmd-2.0.1/s3cmd ]]; then + rm -rf s3cmd-2.0.1.tar.gz s3cmd-2.0.1 + $DRYRUN wget https://github.com/s3tools/s3cmd/releases/download/v2.0.1/s3cmd-2.0.1.tar.gz + $DRYRUN tar zxf s3cmd-2.0.1.tar.gz + fi + + $DRYRUN python ./s3cmd-2.0.1/s3cmd --acl-public put solana-release.tar.bz2 \ + s3://solana-release/"$CHANNEL_OR_TAG"/solana-release.tar.bz2 + ) + else + echo Skipped due to DRYRUN + fi fi exit 0 diff --git a/ci/solana-testnet.yml b/ci/solana-testnet.yml index c85ae4521336cd..296bbc4ceca489 100755 --- a/ci/solana-testnet.yml +++ b/ci/solana-testnet.yml @@ -1,9 +1,4 @@ steps: - - command: "test -n $USE_PREBUILT_CHANNEL_TARBALL || ci/snap.sh" - label: "create snap" - - - wait - - command: "ci/testnet-automation.sh" label: "run testnet" agents: diff --git a/ci/testnet-automation.sh b/ci/testnet-automation.sh index 3b365d32aa5f7b..fcc36c56452e87 100755 --- a/ci/testnet-automation.sh +++ b/ci/testnet-automation.sh @@ -4,8 +4,8 @@ set -e cd "$(dirname "$0")/.." if [[ -z $USE_PREBUILT_CHANNEL_TARBALL ]]; then - echo --- downloading snap from build artifacts - buildkite-agent artifact download "solana_*.snap" . + echo --- downloading tar from build artifacts + buildkite-agent artifact download "solana*.tar.bz2" . fi # shellcheck disable=SC1091 @@ -35,7 +35,7 @@ launchTestnet() { if [[ -n $USE_PREBUILT_CHANNEL_TARBALL ]]; then net/net.sh start -o noValidatorSanity -t "$CHANNEL" else - net/net.sh start -o noValidatorSanity -S solana_*.snap + net/net.sh start -o noValidatorSanity -T solana*.tar.bz2 fi echo --- wait "$ITERATION_WAIT" seconds to complete test