Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
[ci] fix publish-docker-substrate job (#11218)
Browse files Browse the repository at this point in the history
  • Loading branch information
alvicsam authored Apr 13, 2022
1 parent 32510e1 commit 1f4cd99
Showing 1 changed file with 18 additions and 30 deletions.
48 changes: 18 additions & 30 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,13 @@ variables: &default-vars
CI_IMAGE: "paritytech/ci-linux:production"

default:
retry:
max: 2
when:
- runner_system_failure
- unknown_failure
- api_failure
interruptible: true
cache: {}

.collect-artifacts: &collect-artifacts
Expand All @@ -60,13 +67,6 @@ default:
- artifacts/

.kubernetes-env: &kubernetes-env
retry:
max: 2
when:
- runner_system_failure
- unknown_failure
- api_failure
interruptible: true
tags:
- kubernetes-parity-build

Expand All @@ -81,13 +81,6 @@ default:
image: "${CI_IMAGE}"
before_script:
- *rust-info-script
retry:
max: 2
when:
- runner_system_failure
- unknown_failure
- api_failure
interruptible: true
tags:
- linux-docker

Expand Down Expand Up @@ -170,21 +163,6 @@ default:
| tee ./artifacts/benches/$CI_COMMIT_REF_NAME-$CI_COMMIT_SHORT_SHA/::trie::read::small.json'
- sccache -s

.build-linux-substrate-script: &build-linux-substrate-script
- WASM_BUILD_NO_COLOR=1 time cargo build --release --verbose
- mv ./target/release/substrate ./artifacts/substrate/.
- echo -n "Substrate version = "
- if [ "${CI_COMMIT_TAG}" ]; then
echo "${CI_COMMIT_TAG}" | tee ./artifacts/substrate/VERSION;
else
./artifacts/substrate/substrate --version |
sed -n -E 's/^substrate ([0-9.]+.*-[0-9a-f]{7,13})-.*$/\1/p' |
tee ./artifacts/substrate/VERSION;
fi
- sha256sum ./artifacts/substrate/substrate | tee ./artifacts/substrate/substrate.sha256
- cp -r ./scripts/ci/docker/substrate.Dockerfile ./artifacts/substrate/
- sccache -s


#### stage: .pre

Expand Down Expand Up @@ -525,7 +503,17 @@ build-linux-substrate:
before_script:
- mkdir -p ./artifacts/substrate/
script:
- *build-linux-substrate-script
- WASM_BUILD_NO_COLOR=1 time cargo build --release --verbose
- mv ./target/release/substrate ./artifacts/substrate/.
- echo -n "Substrate version = "
- if [ "${CI_COMMIT_TAG}" ]; then
echo "${CI_COMMIT_TAG}" | tee ./artifacts/substrate/VERSION;
else
./artifacts/substrate/substrate --version |
cut -d ' ' -f 2 | tee ./artifacts/substrate/VERSION;
fi
- sha256sum ./artifacts/substrate/substrate | tee ./artifacts/substrate/substrate.sha256
- cp -r ./scripts/ci/docker/substrate.Dockerfile ./artifacts/substrate/
- printf '\n# building node-template\n\n'
- ./scripts/ci/node-template-release.sh ./artifacts/substrate/substrate-node-template.tar.gz

Expand Down

0 comments on commit 1f4cd99

Please sign in to comment.