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

Commit

Permalink
[ci] fix implementer guide job (#6357)
Browse files Browse the repository at this point in the history
* [DNM] debug implementer guide job

* remove git depth

* change git strategy

* add git depth

* try k8s runner

* fix k8s template

* test job

* fix test

* fix

* return pipeline back

* enable disabled deploy-parity-testnet
  • Loading branch information
alvicsam committed Nov 28, 2022
1 parent e5602d4 commit 7538b76
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 25 deletions.
28 changes: 9 additions & 19 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,21 @@ variables:
GIT_DEPTH: 100
CI_SERVER_NAME: "GitLab CI"
CI_IMAGE: "paritytech/ci-linux:production"
BUILDAH_IMAGE: "quay.io/buildah/stable:v1.27"
DOCKER_OS: "debian:stretch"
ARCH: "x86_64"
ZOMBIENET_IMAGE: "docker.io/paritytech/zombienet:v1.2.78"
PIPELINE_SCRIPTS_TAG: "v0.4"

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

.collect-artifacts:
artifacts:
Expand Down Expand Up @@ -72,25 +80,12 @@ default:
dotenv: pipeline-stopper.env

.kubernetes-env:
retry:
max: 2
when:
- runner_system_failure
- unknown_failure
- api_failure
interruptible: true
image: "${CI_IMAGE}"
tags:
- kubernetes-parity-build

.docker-env:
image: "${CI_IMAGE}"
retry:
max: 2
when:
- runner_system_failure
- unknown_failure
- api_failure
interruptible: true
tags:
- linux-docker

Expand Down Expand Up @@ -150,9 +145,6 @@ default:
- if: $CI_COMMIT_REF_NAME =~ /^v[0-9]+\.[0-9]+.*$/ # i.e. v1.0, v2.1rc1

.build-push-image:
extends:
- .kubernetes-env
image: quay.io/buildah/stable:v1.27
before_script:
- test -s ./artifacts/VERSION || exit 1
- test -s ./artifacts/EXTRATAG || exit 1
Expand Down Expand Up @@ -196,8 +188,6 @@ include:
# zombienet jobs
- scripts/ci/gitlab/pipeline/zombienet.yml



#### stage: .post

deploy-parity-testnet:
Expand Down
6 changes: 2 additions & 4 deletions scripts/ci/gitlab/pipeline/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ build-linux-stable:
RUN_UI_TESTS: 1
script:
- time cargo build --profile testnet --features pyroscope --verbose --bin polkadot
- sccache -s
# pack artifacts
- mkdir -p ./artifacts
- VERSION="${CI_COMMIT_REF_NAME}" # will be tag or branch name
Expand Down Expand Up @@ -98,7 +97,6 @@ build-malus:
- .collect-artifacts
script:
- time cargo build --profile testnet --verbose -p polkadot-test-malus
- sccache -s
# pack artifacts
- mkdir -p ./artifacts
- mv ./target/testnet/malus ./artifacts/.
Expand Down Expand Up @@ -165,18 +163,18 @@ build-implementers-guide:
- job: test-deterministic-wasm
artifacts: false
extends:
- .docker-env
- .kubernetes-env
- .test-refs
- .collect-artifacts-short
# git depth is set on purpose: https://github.com/paritytech/polkadot/issues/6284
variables:
GIT_STRATEGY: clone
GIT_DEPTH: 0
CI_IMAGE: paritytech/mdbook-utils:e14aae4a-20221123
script:
- mdbook build ./roadmap/implementers-guide
- mkdir -p artifacts
- mv roadmap/implementers-guide/book artifacts/
- ls -la artifacts/

build-short-benchmark:
stage: build
Expand Down
13 changes: 11 additions & 2 deletions scripts/ci/gitlab/pipeline/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
publish-polkadot-debug-image:
stage: publish
extends:
- .kubernetes-env
- .build-push-image
rules:
# Don't run when triggered from another pipeline
Expand All @@ -18,6 +19,7 @@ publish-polkadot-debug-image:
- if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs
- if: $CI_COMMIT_REF_NAME =~ /^v[0-9]+\.[0-9]+.*$/ # i.e. v1.0, v2.1rc1
variables:
CI_IMAGE: ${BUILDAH_IMAGE}
GIT_STRATEGY: none
DOCKER_USER: ${PARITYPR_USER}
DOCKER_PASS: ${PARITYPR_PASS}
Expand All @@ -42,9 +44,11 @@ publish-test-collators-image:
# service image for Simnet
stage: publish
extends:
- .kubernetes-env
- .build-push-image
- .zombienet-refs
variables:
CI_IMAGE: ${BUILDAH_IMAGE}
GIT_STRATEGY: none
DOCKER_USER: ${PARITYPR_USER}
DOCKER_PASS: ${PARITYPR_PASS}
Expand All @@ -68,9 +72,11 @@ publish-malus-image:
# service image for Simnet
stage: publish
extends:
- .kubernetes-env
- .build-push-image
- .zombienet-refs
variables:
CI_IMAGE: ${BUILDAH_IMAGE}
GIT_STRATEGY: none
DOCKER_USER: ${PARITYPR_USER}
DOCKER_PASS: ${PARITYPR_PASS}
Expand All @@ -93,9 +99,11 @@ publish-malus-image:
publish-staking-miner-image:
stage: publish
extends:
- .kubernetes-env
- .build-push-image
- .publish-refs
variables:
CI_IMAGE: ${BUILDAH_IMAGE}
# scripts/ci/dockerfiles/staking-miner/staking-miner_injected.Dockerfile
DOCKERFILE: ci/dockerfiles/staking-miner/staking-miner_injected.Dockerfile
IMAGE_NAME: docker.io/paritytech/staking-miner
Expand All @@ -114,8 +122,8 @@ publish-s3-release:
needs:
- job: build-linux-stable
artifacts: true
image: paritytech/awscli:latest
variables:
CI_IMAGE: paritytech/awscli:latest
GIT_STRATEGY: none
PREFIX: "builds/polkadot/${ARCH}-${DOCKER_OS}"
rules:
Expand Down Expand Up @@ -152,7 +160,8 @@ publish-rustdoc:
stage: publish
extends:
- .kubernetes-env
image: paritytech/tools:latest
variables:
CI_IMAGE: paritytech/tools:latest
rules:
- if: $CI_PIPELINE_SOURCE == "pipeline"
when: never
Expand Down

0 comments on commit 7538b76

Please sign in to comment.