Skip to content
This repository was archived by the owner on Oct 3, 2025. It is now read-only.

Commit 1f4cd99

Browse files
authored
[ci] fix publish-docker-substrate job (paritytech#11218)
1 parent 32510e1 commit 1f4cd99

File tree

1 file changed

+18
-30
lines changed

1 file changed

+18
-30
lines changed

.gitlab-ci.yml

Lines changed: 18 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,13 @@ variables: &default-vars
4141
CI_IMAGE: "paritytech/ci-linux:production"
4242

4343
default:
44+
retry:
45+
max: 2
46+
when:
47+
- runner_system_failure
48+
- unknown_failure
49+
- api_failure
50+
interruptible: true
4451
cache: {}
4552

4653
.collect-artifacts: &collect-artifacts
@@ -60,13 +67,6 @@ default:
6067
- artifacts/
6168

6269
.kubernetes-env: &kubernetes-env
63-
retry:
64-
max: 2
65-
when:
66-
- runner_system_failure
67-
- unknown_failure
68-
- api_failure
69-
interruptible: true
7070
tags:
7171
- kubernetes-parity-build
7272

@@ -81,13 +81,6 @@ default:
8181
image: "${CI_IMAGE}"
8282
before_script:
8383
- *rust-info-script
84-
retry:
85-
max: 2
86-
when:
87-
- runner_system_failure
88-
- unknown_failure
89-
- api_failure
90-
interruptible: true
9184
tags:
9285
- linux-docker
9386

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

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

189167
#### stage: .pre
190168

@@ -525,7 +503,17 @@ build-linux-substrate:
525503
before_script:
526504
- mkdir -p ./artifacts/substrate/
527505
script:
528-
- *build-linux-substrate-script
506+
- WASM_BUILD_NO_COLOR=1 time cargo build --release --verbose
507+
- mv ./target/release/substrate ./artifacts/substrate/.
508+
- echo -n "Substrate version = "
509+
- if [ "${CI_COMMIT_TAG}" ]; then
510+
echo "${CI_COMMIT_TAG}" | tee ./artifacts/substrate/VERSION;
511+
else
512+
./artifacts/substrate/substrate --version |
513+
cut -d ' ' -f 2 | tee ./artifacts/substrate/VERSION;
514+
fi
515+
- sha256sum ./artifacts/substrate/substrate | tee ./artifacts/substrate/substrate.sha256
516+
- cp -r ./scripts/ci/docker/substrate.Dockerfile ./artifacts/substrate/
529517
- printf '\n# building node-template\n\n'
530518
- ./scripts/ci/node-template-release.sh ./artifacts/substrate/substrate-node-template.tar.gz
531519

0 commit comments

Comments
 (0)