diff --git a/polkadot/.gitlab-ci.yml b/polkadot/.gitlab-ci.yml index 0a0509d939..14295f7c3c 100644 --- a/polkadot/.gitlab-ci.yml +++ b/polkadot/.gitlab-ci.yml @@ -2,12 +2,12 @@ # # polkadot # -# pipelines can be triggered manually in the web -# setting DEPLOY_TAG will only deploy the tagged image +# Pipelines can be triggered manually in the web. # -# please do not add new jobs without "rules:" and "*-env". There are &test-refs for everything, -# &test-and-rococo-refs preset. And "kubernetes-env" with "docker-env" to set a runner -# which executes the job. +# Please do not add new jobs without "rules:" and "*-env". There are &test-refs for everything, +# "docker-env" is used for Rust jobs. +# And "kubernetes-env" for everything else. Please mention "image:" container name to be used +# with it, as there's no default one. stages: - test @@ -73,23 +73,14 @@ default: - cargo --version - sccache -s -.test-refs: &test-refs +.test-refs: &test-refs # these jobs run always* rules: - - if: $CI_COMMIT_REF_NAME == "rococo-v1" - when: never - if: $CI_PIPELINE_SOURCE == "schedule" - if: $CI_COMMIT_REF_NAME == "master" - if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs -.test-and-rococo-refs: &test-and-rococo-refs - rules: - - if: $CI_PIPELINE_SOURCE == "schedule" - - if: $CI_COMMIT_REF_NAME == "master" - - if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs - - if: $CI_COMMIT_REF_NAME == "rococo-v1" - -.test-pr-refs: &test-pr-refs +.test-pr-refs: &test-pr-refs rules: - if: $CI_PIPELINE_SOURCE == "pipeline" when: never @@ -102,7 +93,6 @@ default: - if: $CI_PIPELINE_SOURCE == "schedule" - if: $CI_COMMIT_REF_NAME == "master" - if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs - - if: $CI_COMMIT_REF_NAME == "rococo-v1" .publish-refs: &publish-refs rules: @@ -212,7 +202,6 @@ test-build-linux-stable: - if: $CI_COMMIT_REF_NAME == "master" - if: $CI_COMMIT_REF_NAME =~ /^v[0-9]+\.[0-9]+.*$/ # i.e. v1.0, v2.1rc1 - if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs - - if: $CI_COMMIT_REF_NAME == "rococo-v1" script: - ./scripts/gitlab/test_linux_stable.sh # we're using the bin built here, instead of having a parallel `build-linux-release` @@ -275,7 +264,7 @@ build-adder-collator: <<: *collect-artifacts <<: *docker-env <<: *compiler-info - <<: *test-and-rococo-refs + <<: *test-refs script: - time cargo build --profile testnet --verbose -p test-parachain-adder-collator - sccache -s @@ -292,7 +281,7 @@ build-malus: <<: *collect-artifacts <<: *docker-env <<: *compiler-info - <<: *test-and-rococo-refs + <<: *test-refs script: - time cargo build --profile testnet --verbose -p polkadot-test-malus - sccache -s @@ -433,12 +422,6 @@ publish-polkadot-image: - if: $CI_PIPELINE_SOURCE == "schedule" - if: $CI_COMMIT_REF_NAME == "master" - if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs - - if: $CI_COMMIT_REF_NAME == "rococo-v1" - variables: - <<: *image-variables - IMAGE_NAME: docker.io/parity/rococo - DOCKER_USER: ${DOCKER_HUB_USER} - DOCKER_PASS: ${DOCKER_HUB_PASS} needs: - job: test-build-linux-stable artifacts: true @@ -635,10 +618,8 @@ zombienet-tests-parachains-smoke-test: - job: publish-polkadot-image - job: publish-malus-image - job: publish-adder-collator-image - variables: - GH_DIR: 'https://github.com/paritytech/polkadot/tree/${CI_COMMIT_SHORT_SHA}/zombienet_tests/parachains' - + GH_DIR: "https://github.com/paritytech/polkadot/tree/${CI_COMMIT_SHORT_SHA}/zombienet_tests/parachains" before_script: - echo "Zombie-net Tests Config" - echo "${ZOMBIENET_IMAGE}" @@ -649,7 +630,6 @@ zombienet-tests-parachains-smoke-test: - export ZOMBIENET_INTEGRATION_TEST_IMAGE=${PARACHAINS_IMAGE_NAME}:${PARACHAINS_IMAGE_TAG} - export MALUS_IMAGE=${MALUS_IMAGE_NAME}:${MALUS_IMAGE_TAG} - export COL_IMAGE="docker.io/paritypr/colander:4519" # The collator image is fixed - script: - /home/nonroot/zombie-net/scripts/run-test-env-manager.sh --github-remote-dir="${GH_DIR}" @@ -668,10 +648,8 @@ zombienet-tests-malus-dispute-valid: - job: publish-polkadot-image - job: publish-malus-image - job: publish-adder-collator-image - variables: - GH_DIR: 'https://github.com/paritytech/polkadot/tree/${CI_COMMIT_SHORT_SHA}/node/malus/integrationtests' - + GH_DIR: "https://github.com/paritytech/polkadot/tree/${CI_COMMIT_SHORT_SHA}/node/malus/integrationtests" before_script: - echo "Zombie-net Tests Config" - echo "${ZOMBIENET_IMAGE_NAME}" @@ -682,7 +660,6 @@ zombienet-tests-malus-dispute-valid: - export ZOMBIENET_INTEGRATION_TEST_IMAGE=${PARACHAINS_IMAGE_NAME}:${PARACHAINS_IMAGE_TAG} - export MALUS_IMAGE=${MALUS_IMAGE_NAME}:${MALUS_IMAGE_TAG} - export COL_IMAGE=${COLLATOR_IMAGE_NAME}:${COLLATOR_IMAGE_TAG} - script: - /home/nonroot/zombie-net/scripts/run-test-env-manager.sh --github-remote-dir="${GH_DIR}"