From 1fb11c23d8d346733695cf78a20306dfdc3c3664 Mon Sep 17 00:00:00 2001 From: "Denis S. Soldatov aka General-Beck" Date: Wed, 7 Jun 2017 21:53:36 +0300 Subject: [PATCH] port snap build --- .gitlab-ci.yml | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 0a9f8d543..2763c0cca 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -69,17 +69,29 @@ linux-snap: - tags - triggers script: - - rm -rf *snap + - export VER=$(grep -m 1 version Cargo.toml | awk '{print $3}' | tr -d '"' | tr -d "\n") - cd scripts + - rm -rf *snap + - sed -i 's/master/'"$VER"'/g' snapcraft.yaml + - echo "Version:"$VER - snapcraft + - ls + - cp 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_master_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