From f1cd03bf1f7d6246bbb0927e0d978e6f5d0407b9 Mon Sep 17 00:00:00 2001 From: "Denis S. Soldatov aka General-Beck" Date: Wed, 7 Jun 2017 19:41:45 +0300 Subject: [PATCH] add snap package --- .gitlab-ci.yml | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ef0e2e97a..c62465534 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -63,19 +63,33 @@ linux-snap: stage: build image: parity/snapcraft:gitlab-ci only: + - snap - beta + - tags + - triggers script: - rm -rf *snap - cd scripts + - rm -rf *snap + - export VER=$(grep -m 1 version Cargo.toml | awk '{print $3}' | tr -d '"' | tr -d "\n") + - sed -i 's/master/'"$VER"'/g' snapcraft.yaml - snapcraft + - cp scripts/parity_master_amd64.snap parity_"$VER"_amd64.snap + - md5sum "parity_"$VER"_amd64.snap" > "parity_"$VER"_amd64.snap.md5" + - aws configure set aws_access_key_id $s3_key + - aws configure set aws_secret_access_key $s3_secret + - if [[ $CI_BUILD_REF_NAME =~ ^(master|beta|stable|nightly)$ ]]; then export S3_BUCKET=builds-parity-published; else export S3_BUCKET=builds-parity; fi + - aws s3api put-object --bucket $S3_BUCKET --key $CI_BUILD_REF_NAME/x86_64-unknown-linux-gnu/"parity_"$VER"_amd64.snap" --body "parity_"$VER"_amd64.snap" + - aws s3api put-object --bucket $S3_BUCKET --key $CI_BUILD_REF_NAME/x86_64-unknown-linux-gnu/"parity_"$VER"_amd64.snap.md5" --body "parity_"$VER"_amd64.snap.md5" + - curl --data "commit=$CI_BUILD_REF&sha3=$SHA3&filename=parity&secret=$RELEASES_SECRET" http://update.parity.io:1337/push-build/$CI_BUILD_REF_NAME/x86_64-unknown-linux-gnu + - curl --data "commit=$CI_BUILD_REF&sha3=$SHA3&filename=parity&secret=$RELEASES_SECRET" http://update.parity.io:1338/push-build/$CI_BUILD_REF_NAME/x86_64-unknown-linux-gnu tags: - rust - rust-stable artifacts: paths: - - scripts/parity_beta_amd64.snap - name: "stable-x86_64-unknown-linux-gnu_parity-snap" - allow_failure: true + - scripts/parity_*_amd64.snap + name: "stable-x86_64-unknown-snap-gnu_parity" linux-stable-debian: stage: build image: parity/rust-debian:gitlab-ci