From acd043bc5fc9acfa384b69c33e341f925ef250a7 Mon Sep 17 00:00:00 2001 From: Svyatoslav Nikolsky Date: Fri, 26 Jan 2024 15:45:23 +0300 Subject: [PATCH] Remove bridges zombienet tests from CI (#3071) closes https://github.com/paritytech/parity-bridges-common/issues/2796 This partially reverts the #2439 - there are some changes (unrelated to CI) that we still want to keep. The reason of that removal is that with async backing enabled for Rococo AH (and for other chains in the near future), we see a lot of issues there (because we run `14` nodes + additional standalone process within a same container and it causes a lot of timeouts). There's no way known to me to fix it right now, so we're removing those tests hopefully temporarily to keep CI green --- .gitlab/pipeline/build.yml | 18 ------ .gitlab/pipeline/publish.yml | 22 ------- .gitlab/pipeline/zombienet.yml | 2 - .gitlab/pipeline/zombienet/bridges.yml | 54 ----------------- ...ridges_zombienet_tests_injected.Dockerfile | 60 ------------------- 5 files changed, 156 deletions(-) delete mode 100644 .gitlab/pipeline/zombienet/bridges.yml delete mode 100644 docker/dockerfiles/bridges_zombienet_tests_injected.Dockerfile diff --git a/.gitlab/pipeline/build.yml b/.gitlab/pipeline/build.yml index d998b62c8993..20aa4a5c2a28 100644 --- a/.gitlab/pipeline/build.yml +++ b/.gitlab/pipeline/build.yml @@ -382,21 +382,3 @@ build-subkey-linux: # after_script: [""] # tags: # - osx - -# bridges - -# we need some non-binary artifacts in our bridges+zombienet image -prepare-bridges-zombienet-artifacts: - stage: build - extends: - - .docker-env - - .common-refs - - .run-immediately - - .collect-artifacts - before_script: - - mkdir -p ./artifacts/bridges-polkadot-sdk/bridges - - mkdir -p ./artifacts/bridges-polkadot-sdk/cumulus/zombienet - script: - - cp -r bridges/zombienet ./artifacts/bridges-polkadot-sdk/bridges/zombienet - - cp -r cumulus/scripts ./artifacts/bridges-polkadot-sdk/cumulus/scripts - - cp -r cumulus/zombienet/bridge-hubs ./artifacts/bridges-polkadot-sdk/cumulus/zombienet/bridge-hubs diff --git a/.gitlab/pipeline/publish.yml b/.gitlab/pipeline/publish.yml index b73acb560f67..3b77f5363f62 100644 --- a/.gitlab/pipeline/publish.yml +++ b/.gitlab/pipeline/publish.yml @@ -66,8 +66,6 @@ publish-rustdoc: # note: images are used not only in zombienet but also in rococo, wococo and versi .build-push-image: image: $BUILDAH_IMAGE - extends: - - .zombienet-refs variables: DOCKERFILE: "" # docker/path-to.Dockerfile IMAGE_NAME: "" # docker.io/paritypr/image_name @@ -79,7 +77,6 @@ publish-rustdoc: --build-arg VCS_REF="${CI_COMMIT_SHA}" --build-arg BUILD_DATE="$(date -u '+%Y-%m-%dT%H:%M:%SZ')" --build-arg IMAGE_NAME="${IMAGE_NAME}" - --build-arg ZOMBIENET_IMAGE="${ZOMBIENET_IMAGE}" --tag "$IMAGE_NAME:${DOCKER_IMAGES_VERSION}" --file ${DOCKERFILE} . - echo "$PARITYPR_PASS" | @@ -166,22 +163,3 @@ build-push-image-substrate-pr: variables: DOCKERFILE: "docker/dockerfiles/substrate_injected.Dockerfile" IMAGE_NAME: "docker.io/paritypr/substrate" - -# unlike other images, bridges+zombienet image is based on Zombienet image that pulls required binaries -# from other fresh images (polkadot and cumulus) -build-push-image-bridges-zombienet-tests: - stage: publish - extends: - - .kubernetes-env - - .common-refs - - .build-push-image - needs: - - job: build-linux-stable - artifacts: true - - job: build-linux-stable-cumulus - artifacts: true - - job: prepare-bridges-zombienet-artifacts - artifacts: true - variables: - DOCKERFILE: "docker/dockerfiles/bridges_zombienet_tests_injected.Dockerfile" - IMAGE_NAME: "docker.io/paritypr/bridges-zombienet-tests" diff --git a/.gitlab/pipeline/zombienet.yml b/.gitlab/pipeline/zombienet.yml index 55120e66d0e5..a1d4db580cca 100644 --- a/.gitlab/pipeline/zombienet.yml +++ b/.gitlab/pipeline/zombienet.yml @@ -10,5 +10,3 @@ include: - .gitlab/pipeline/zombienet/cumulus.yml # polkadot tests - .gitlab/pipeline/zombienet/polkadot.yml - # bridges tests - - .gitlab/pipeline/zombienet/bridges.yml diff --git a/.gitlab/pipeline/zombienet/bridges.yml b/.gitlab/pipeline/zombienet/bridges.yml deleted file mode 100644 index 9414207a3bbf..000000000000 --- a/.gitlab/pipeline/zombienet/bridges.yml +++ /dev/null @@ -1,54 +0,0 @@ -# This file is part of .gitlab-ci.yml -# Here are all jobs that are executed during "zombienet" stage for bridges - -# common settings for all zombienet jobs -.zombienet-bridges-common: - before_script: - # Exit if the job is not merge queue - # - if [[ $CI_COMMIT_REF_NAME != *"gh-readonly-queue"* ]]; then echo "I will run only in a merge queue"; exit 0; fi - - echo "Zombienet Tests Config" - - echo "${ZOMBIENET_IMAGE}" - - echo "${GH_DIR}" - - echo "${LOCAL_DIR}" - - ls "${LOCAL_DIR}" - - export DEBUG=zombie,zombie::network-node - - export ZOMBIENET_INTEGRATION_TEST_IMAGE="${BRIDGES_ZOMBIENET_TESTS_IMAGE}":${BRIDGES_ZOMBIENET_TESTS_IMAGE_TAG} - - echo "${ZOMBIENET_INTEGRATION_TEST_IMAGE}" - stage: zombienet - image: "${BRIDGES_ZOMBIENET_TESTS_IMAGE}:${BRIDGES_ZOMBIENET_TESTS_IMAGE_TAG}" - needs: - - job: build-push-image-bridges-zombienet-tests - artifacts: true - extends: - - .kubernetes-env - - .zombienet-refs - variables: - BRIDGES_ZOMBIENET_TESTS_IMAGE_TAG: ${DOCKER_IMAGES_VERSION} - BRIDGES_ZOMBIENET_TESTS_IMAGE: "docker.io/paritypr/bridges-zombienet-tests" - GH_DIR: "https://github.com/paritytech/polkadot-sdk/tree/${CI_COMMIT_SHA}/bridges/zombienet" - LOCAL_DIR: "/builds/parity/mirrors/polkadot-sdk/bridges/zombienet" - FF_DISABLE_UMASK_FOR_DOCKER_EXECUTOR: 1 - RUN_IN_CONTAINER: "1" - artifacts: - name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}_zombienet_bridge_tests" - when: always - expire_in: 2 days - paths: - - ./zombienet-logs - after_script: - - mkdir -p ./zombienet-logs - # copy logs of tests runner (run-tests.sh) - - cp -r /tmp/bridges-zombienet-tests.*/tmp.*/tmp.* ./zombienet-logs/ - # copy logs of all nodes - - cp /tmp/zombie*/logs/* ./zombienet-logs/ -# following lines are causing spurious test failures ("At least one of the nodes fails to start") -# retry: 2 -# tags: -# - zombienet-polkadot-integration-test - -zombienet-bridges-0001-asset-transfer-works: - extends: - - .zombienet-bridges-common - script: - - /home/nonroot/bridges-polkadot-sdk/bridges/zombienet/run-tests.sh --docker - - echo "Done" diff --git a/docker/dockerfiles/bridges_zombienet_tests_injected.Dockerfile b/docker/dockerfiles/bridges_zombienet_tests_injected.Dockerfile deleted file mode 100644 index ebad4046d268..000000000000 --- a/docker/dockerfiles/bridges_zombienet_tests_injected.Dockerfile +++ /dev/null @@ -1,60 +0,0 @@ -# this image is built on top of existing Zombienet image -ARG ZOMBIENET_IMAGE -# this image uses substrate-relay image built elsewhere -ARG SUBSTRATE_RELAY_IMAGE=docker.io/paritytech/substrate-relay:v2023-11-07-rococo-westend-initial-relayer - -# metadata -ARG VCS_REF -ARG BUILD_DATE -ARG IMAGE_NAME - -# we need `substrate-relay` binary, built elsewhere -FROM ${SUBSTRATE_RELAY_IMAGE} as relay-builder - -# the base image is the zombienet image - we are planning to run zombienet tests using native -# provider here -FROM ${ZOMBIENET_IMAGE} - -LABEL io.parity.image.authors="devops-team@parity.io" \ - io.parity.image.vendor="Parity Technologies" \ - io.parity.image.title="${IMAGE_NAME}" \ - io.parity.image.description="Bridges Zombienet tests." \ - io.parity.image.source="https://github.com/paritytech/polkadot-sdk/blob/${VCS_REF}/docker/dockerfiles/bridges_zombienet_tests_injected.Dockerfile" \ - io.parity.image.revision="${VCS_REF}" \ - io.parity.image.created="${BUILD_DATE}" \ - io.parity.image.documentation="https://github.com/paritytech/polkadot-sdk/bridges/zombienet" - -# show backtraces -ENV RUST_BACKTRACE 1 -USER root - -# for native provider to work (TODO: fix in zn docker?) -RUN apt-get update && apt-get install -y procps sudo -RUN yarn global add @polkadot/api-cli - -# add polkadot binary to the docker image -COPY ./artifacts/polkadot /usr/local/bin/ -COPY ./artifacts/polkadot-execute-worker /usr/local/bin/ -COPY ./artifacts/polkadot-prepare-worker /usr/local/bin/ -# add polkadot-parachain binary to the docker image -COPY ./artifacts/polkadot-parachain /usr/local/bin -# copy substrate-relay to the docker image -COPY --from=relay-builder /home/user/substrate-relay /usr/local/bin/ -# we need bridges zombienet runner and tests -RUN mkdir -p /home/nonroot/bridges-polkadot-sdk -COPY ./artifacts/bridges-polkadot-sdk /home/nonroot/bridges-polkadot-sdk -# also prepare `generate_hex_encoded_call` for running -RUN set -eux; \ - cd /home/nonroot/bridges-polkadot-sdk/cumulus/scripts/generate_hex_encoded_call; \ - npm install - -# check if executable works in this container -USER nonroot -RUN /usr/local/bin/polkadot --version -RUN /usr/local/bin/polkadot-parachain --version -RUN /usr/local/bin/substrate-relay --version - -# https://polkadot.js.org/apps/?rpc=ws://127.0.0.1:{PORT}#/explorer -EXPOSE 9942 9910 8943 9945 9010 8945 - -ENTRYPOINT ["/bin/bash", "-c", "/home/nonroot/bridges-polkadot-sdk/bridges/zombienet/run-tests.sh"]