@@ -64,22 +64,14 @@ variables:
6464 - schedules
6565 - web
6666 - /^v[0-9]+\.[0-9]+.*$/ # i.e. v1.0, v2.1rc1
67- - kusama-nightly-staging
68- except :
69- variables :
70- - $DEPLOY_TAG
7167
7268.test-refs : &test-refs
7369 only :
7470 - master
7571 - schedules
7672 - web
7773 - /^v[0-9]+\.[0-9]+.*$/ # i.e. v1.0, v2.1rc1
78- - kusama-nightly-staging
7974 - /^[0-9]+$/
80- except :
81- variables :
82- - $DEPLOY_TAG
8375
8476
8577
@@ -134,13 +126,7 @@ test-linux-stable: &test
134126 RUSTFLAGS : -Cdebug-assertions=y
135127 TARGET : native
136128 script :
137- - |
138- test "${CI_COMMIT_REF_NAME}" = "kusama-nightly-staging" && (
139- echo "kusama-nightly-staging: change Cargo.toml to build against substrate:kusama-nightly-staging"
140- find . -name Cargo.toml -exec sed -i -r -e ':github.com/paritytech/substrate": { s:branch = "polkadot-(master|testing)":branch = "kusama-nightly-staging":; s:github.com/paritytech/substrate:gitlab.parity.io/parity/substrate.git:}' '{}' \;
141- sed -i -r 's:github.com/paritytech/substrate\?branch=polkadot-(master|testing):gitlab.parity.io/parity/substrate.git?branch=kusama-nightly-staging:' Cargo.lock
142- time cargo test --all --release --verbose) || \
143- time cargo test --all --release --verbose --locked
129+ - time cargo test --all --release --verbose --locked
144130 - sccache -s
145131
146132
@@ -180,11 +166,6 @@ build-linux-release: &build
180166 << : *docker-env
181167 << : *compiler_info
182168 script :
183- - |
184- test "${CI_COMMIT_REF_NAME}" = "kusama-nightly-staging" && (
185- echo "kusama-nightly-staging: change Cargo.toml to build against substrate:kusama-nightly-staging"
186- find . -name Cargo.toml -exec sed -i -r -e ':github.com/paritytech/substrate": { s:branch = "polkadot-(master|testing)":branch = "kusama-nightly-staging":; s:github.com/paritytech/substrate:gitlab.parity.io/parity/substrate.git:}' '{}' \;
187- sed -i -r 's:github.com/paritytech/substrate\?branch=polkadot-(master|testing):gitlab.parity.io/parity/substrate.git?branch=kusama-nightly-staging:' Cargo.lock )
188169 - time cargo build --release --verbose
189170 - mkdir -p ./artifacts
190171 - mv ./target/release/polkadot ./artifacts/.
@@ -289,99 +270,15 @@ publish-s3-release:
289270
290271
291272
292- .deploy-template : &deploy
293- stage : deploy
294- when : manual
295- cache : {}
296- retry : 1
297- image : parity/kubetools:latest
298- << : *build-refs
299- tags :
300- # this is the runner that is used to deploy it
301- - kubernetes-parity-build
302- before_script :
303- - test -z "${DEPLOY_TAG}" &&
304- test "${CI_COMMIT_TAG}" -o -f ./artifacts/VERSION &&
305- DEPLOY_TAG="${CI_COMMIT_TAG:-$(cat ./artifacts/VERSION)}"
306- - test "${DEPLOY_TAG}" || ( echo "Neither DEPLOY_TAG nor VERSION information available"; exit 1 )
307- script :
308- - echo "Polkadot version = ${DEPLOY_TAG}"
309- # or use helm to render the template
310- - helm template
311- --values ./scripts/kubernetes/values.yaml
312- --set image.tag=${DEPLOY_TAG}
313- ./scripts/kubernetes | kubectl apply -f - --dry-run=false
314- - echo "# polkadot namespace"
315- - kubectl -n polkadot get all
316- - echo "# polkadot's nodes' external ip addresses:"
317- - kubectl get nodes -l node=polkadot
318- -o jsonpath='{range .items[*]}{.metadata.name}{"\t"}{range @.status.addresses[?(@.type=="ExternalIP")]}{.address}{"\n"}{end}'
319- - echo "# polkadots' nodes"
320- - kubectl -n polkadot get pods
321- -o jsonpath='{range .items[*]}{.metadata.name}{"\t"}{.spec.nodeName}{"\n"}{end}'
322-
323-
324-
325-
326-
327- .deploy-cibuild : &deploy-cibuild
328- << : *deploy
329- dependencies :
330- - publish-docker-release
331-
332- .deploy-tag : &deploy-tag
333- << : *deploy
334- only :
335- variables :
336- - $DEPLOY_TAG
337- except :
338- variables :
339- - $DEPLOY_TAG == ""
340-
341-
342-
343- # have environment:url eventually point to the logs
344- deploy-ew3 :
345- << : *deploy-cibuild
346- environment :
347- name : parity-prod-ew3
348-
349- deploy-ue1 :
350- << : *deploy-cibuild
351- environment :
352- name : parity-prod-ue1
353-
354- deploy-ew3-tag :
355- << : *deploy-tag
356- environment :
357- name : parity-prod-ew3
358-
359- deploy-ue1-tag :
360- << : *deploy-tag
361- environment :
362- name : parity-prod-ue1
363273
364274
365275
366276deploy-polkasync-kusama :
367277 stage : deploy
368- cache : {}
369- retry : 1
370- image : parity/tools:latest
371- only :
372- - kusama-nightly-staging
373- tags :
374- - kubernetes-parity-build
278+ << : *build-refs
375279 variables :
376- GITLAB_API : " https://gitlab.parity.io/api/v4"
377- GITHUB_API_PROJECT : " parity%2Finfrastructure%2Fparity-testnet"
378- GIT_STRATEGY : none
280+ POLKADOT_CI_COMMIT_NAME : " ${CI_COMMIT_REF_NAME}"
281+ POLKADOT_CI_COMMIT_REF : " ${CI_COMMIT_REF}"
379282 allow_failure : true
380- script :
381- - |
382- echo "kusama-nightly-staging: triggering roll-out on parity-testnet"
383- curl -sS -X POST \
384- -F "token=${CI_JOB_TOKEN}" \
385- -F "ref=master" \
386- -F "variables[POLKADOT_BUILD_REF]=${CI_COMMIT_REF_NAME}" \
387- ${GITLAB_API}/projects/${GITHUB_API_PROJECT}/trigger/pipeline | jq .
283+ trigger : " parity/infrastructure/parity-testnet"
284+
0 commit comments