difftreelog
deleted unnecessary files for xcm and testnet build
in: master
11 files changed
.docker/Dockerfile-testnetdiffbeforeafterboth--- a/.docker/Dockerfile-testnet
+++ /dev/null
@@ -1,96 +0,0 @@
-# ===== Rust builder =====
-FROM ubuntu:20.04 as rust-builder
-LABEL maintainer="Unique.Network"
-
-ARG RUST_TOOLCHAIN=
-
-ENV RUST_TOOLCHAIN $RUST_TOOLCHAIN
-ENV CARGO_HOME="/cargo-home"
-ENV PATH="/cargo-home/bin:$PATH"
-ENV TZ=UTC
-RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
-
-RUN apt-get update && \
- apt-get install -y curl cmake pkg-config libssl-dev git clang llvm libudev-dev && \
- apt-get clean && \
- rm -r /var/lib/apt/lists/*
-
-RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain none
-
-RUN rustup toolchain uninstall $(rustup toolchain list) && \
- rustup toolchain install $RUST_TOOLCHAIN && \
- rustup default $RUST_TOOLCHAIN && \
- rustup target list --installed && \
- rustup show
-RUN rustup target add wasm32-unknown-unknown --toolchain $RUST_TOOLCHAIN
-
-RUN mkdir /unique_parachain
-WORKDIR /unique_parachain
-
-
-# ===== BUILD ======
-FROM rust-builder as builder-unique
-
-ARG PROFILE=release
-ARG FEATURE=
-ARG BRANCH=
-
-
-WORKDIR /unique_parachain
-
-RUN git clone -b $BRANCH https://github.com/UniqueNetwork/unique-chain.git && \
- cd unique-chain && \
- cargo build --features=$FEATURE --$PROFILE
-
-# ===== BUILD POLKADOT =====
-FROM rust-builder as builder-polkadot
-
-ARG POLKADOT_BUILD_BRANCH=
-ENV POLKADOT_BUILD_BRANCH $POLKADOT_BUILD_BRANCH
-
-
-WORKDIR /unique_parachain
-
-RUN git clone -b $POLKADOT_BUILD_BRANCH --depth 1 https://github.com/paritytech/polkadot.git && \
- cd polkadot && \
- cargo build --release
-
-# ===== RUN ======
-
-FROM ubuntu:20.04
-
-ARG POLKADOT_LAUNCH_BRANCH=
-ENV POLKADOT_LAUNCH_BRANCH $POLKADOT_LAUNCH_BRANCH
-
-RUN apt-get -y update && \
- apt-get -y install curl git && \
- curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash && \
- export NVM_DIR="$HOME/.nvm" && \
- [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
- nvm install v16.16.0 && \
- nvm use v16.16.0
-
-RUN git clone https://github.com/uniquenetwork/polkadot-launch -b $POLKADOT_LAUNCH_BRANCH
-
-RUN export NVM_DIR="$HOME/.nvm" && \
- [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
- cd /polkadot-launch && \
- npm install --global yarn && \
- yarn install
-
-COPY --from=builder-unique /unique_parachain/unique-chain/target/release/unique-collator /unique-chain/target/release/
-COPY --from=builder-polkadot /unique_parachain/polkadot/target/release/polkadot /polkadot/target/release/
-
-EXPOSE 9844
-EXPOSE 9944
-EXPOSE 9933
-EXPOSE 9833
-EXPOSE 40333
-EXPOSE 30333
-
-CMD export NVM_DIR="$HOME/.nvm" && \
- [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
- cd /polkadot-launch && \
- yarn start launch-config.json
-
-
.docker/Dockerfile-testnet.j2diffbeforeafterboth--- a/.docker/Dockerfile-testnet.j2
+++ /dev/null
@@ -1,96 +0,0 @@
-# ===== Rust builder =====
-FROM ubuntu:20.04 as rust-builder
-LABEL maintainer="Unique.Network"
-
-#ARG RUST_TOOLCHAIN=
-
-#ENV RUST_TOOLCHAIN $RUST_TOOLCHAIN
-ENV CARGO_HOME="/cargo-home"
-ENV PATH="/cargo-home/bin:$PATH"
-ENV TZ=UTC
-RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
-
-RUN apt-get update && \
- apt-get install -y curl cmake pkg-config libssl-dev git clang llvm libudev-dev && \
- apt-get clean && \
- rm -r /var/lib/apt/lists/*
-
-RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain none
-
-RUN rustup toolchain uninstall $(rustup toolchain list) && \
- rustup toolchain install {{ RUST_TOOLCHAIN }} && \
- rustup default {{ RUST_TOOLCHAIN }} && \
- rustup target list --installed && \
- rustup show
-RUN rustup target add wasm32-unknown-unknown --toolchain {{ RUST_TOOLCHAIN }}
-
-RUN mkdir /unique_parachain
-WORKDIR /unique_parachain
-
-
-# ===== BUILD ======
-FROM rust-builder as builder-unique
-
-ARG PROFILE=release
-#ARG FEATURE=
-#ARG BRANCH=
-
-
-WORKDIR /unique_parachain
-
-RUN git clone -b {{ BRANCH }} https://github.com/UniqueNetwork/unique-chain.git && \
- cd unique-chain && \
- cargo build --features={{ FEATURE }} --$PROFILE
-
-# ===== BUILD POLKADOT =====
-FROM rust-builder as builder-polkadot
-
-#ARG POLKADOT_BUILD_BRANCH=
-#ENV POLKADOT_BUILD_BRANCH $POLKADOT_BUILD_BRANCH
-
-
-WORKDIR /unique_parachain
-
-RUN git clone -b {{ POLKADOT_BUILD_BRANCH }} --depth 1 https://github.com/paritytech/polkadot.git && \
- cd polkadot && \
- cargo build --release
-
-# ===== RUN ======
-
-FROM ubuntu:20.04
-
-#ARG POLKADOT_LAUNCH_BRANCH=
-#ENV POLKADOT_LAUNCH_BRANCH $POLKADOT_LAUNCH_BRANCH
-
-RUN apt-get -y update && \
- apt-get -y install curl git && \
- curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash && \
- export NVM_DIR="$HOME/.nvm" && \
- [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
- nvm install v16.16.0 && \
- nvm use v16.16.0
-
-RUN git clone https://github.com/uniquenetwork/polkadot-launch -b {{ POLKADOT_LAUNCH_BRANCH }}
-
-RUN export NVM_DIR="$HOME/.nvm" && \
- [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
- cd /polkadot-launch && \
- npm install --global yarn && \
- yarn install
-
-COPY --from=builder-unique /unique_parachain/unique-chain/target/release/unique-collator /unique-chain/target/release/
-COPY --from=builder-polkadot /unique_parachain/polkadot/target/release/polkadot /polkadot/target/release/
-
-EXPOSE 9844
-EXPOSE 9944
-EXPOSE 9933
-EXPOSE 9833
-EXPOSE 40333
-EXPOSE 30333
-
-CMD export NVM_DIR="$HOME/.nvm" && \
- [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
- cd /polkadot-launch && \
- yarn start launch-config.json
-
-
.docker/Dockerfile-xcmdiffbeforeafterboth--- a/.docker/Dockerfile-xcm
+++ /dev/null
@@ -1,146 +0,0 @@
-# ===== Rust builder =====
-FROM ubuntu:20.04 as rust-builder
-LABEL maintainer="Unique.Network"
-
-ARG RUST_TOOLCHAIN=
-
-ENV RUST_TOOLCHAIN $RUST_TOOLCHAIN
-ENV CARGO_HOME="/cargo-home"
-ENV PATH="/cargo-home/bin:$PATH"
-ENV TZ=UTC
-RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
-
-RUN apt-get update && \
- apt-get install -y curl cmake pkg-config libssl-dev git clang llvm libudev-dev && \
- apt-get clean && \
- rm -r /var/lib/apt/lists/*
-
-RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain none
-
-RUN rustup toolchain uninstall $(rustup toolchain list) && \
- rustup toolchain install $RUST_TOOLCHAIN && \
- rustup default $RUST_TOOLCHAIN && \
- rustup target list --installed && \
- rustup show
-RUN rustup target add wasm32-unknown-unknown --toolchain $RUST_TOOLCHAIN
-
-RUN mkdir /unique_parachain
-WORKDIR /unique_parachain
-
-
-# ===== BUILD ======
-FROM rust-builder as builder-unique
-
-ARG PROFILE=release
-ARG FEATURE=
-ARG BRANCH=
-
-
-WORKDIR /unique_parachain
-
-RUN git clone -b $BRANCH https://github.com/UniqueNetwork/unique-chain.git && \
- cd unique-chain && \
- cargo build --features=$FEATURE --$PROFILE
-
-# ===== BUILD POLKADOT =====
-FROM rust-builder as builder-polkadot
-
-ARG POLKADOT_BUILD_BRANCH=
-ENV POLKADOT_BUILD_BRANCH $POLKADOT_BUILD_BRANCH
-
-
-WORKDIR /unique_parachain
-
-RUN git clone -b $POLKADOT_BUILD_BRANCH --depth 1 https://github.com/paritytech/polkadot.git && \
- cd polkadot && \
- cargo build --release
-
-# ===== BUILD ACALA =====
-FROM rust-builder as builder-acala
-
-ARG ACALA_BUILD_BRANCH=
-ENV ACALA_BUILD_BRANCH $ACALA_BUILD_BRANCH
-
-
-WORKDIR /unique_parachain
-
-RUN git clone -b $ACALA_BUILD_BRANCH --depth 1 https://github.com/AcalaNetwork/Acala.git && \
- cd Acala && \
- make init && \
- make build-release
-
-# ===== BUILD MOONBEAM =====
-FROM rust-builder as builder-moonbeam
-
-ARG MOONBEAM_BUILD_BRANCH=
-ENV MOONBEAM_BUILD_BRANCH $MOONBEAM_BUILD_BRANCH
-
-
-WORKDIR /unique_parachain
-
-RUN git clone -b $MOONBEAM_BUILD_BRANCH --depth 1 https://github.com/PureStake/moonbeam.git && \
- cd moonbeam && \
- cargo build --release
-
-# ===== BUILD CUMULUS =====
-FROM rust-builder as builder-cumulus
-
-ARG CUMULUS_BUILD_BRANCH=
-ENV CUMULUS_BUILD_BRANCH $CUMULUS_BUILD_BRANCH
-
-
-WORKDIR /unique_parachain
-
-RUN git clone -b $CUMULUS_BUILD_BRANCH --depth 1 https://github.com/paritytech/cumulus.git && \
- cd cumulus && \
- cargo build --release
-
-# ===== BUILD CHAINQL =====
-FROM rust-builder as builder-chainql
-
-RUN mkdir chainql
-WORKDIR /chainql
-
-RUN git clone -b v0.1.0 --depth 1 https://github.com/CertainLach/chainql.git . && \
- cargo build --release
-
-# ===== RUN ======
-
-FROM ubuntu:20.04
-
-ARG POLKADOT_LAUNCH_BRANCH=
-ENV POLKADOT_LAUNCH_BRANCH $POLKADOT_LAUNCH_BRANCH
-
-RUN apt-get -y update && \
- apt-get -y install curl git jsonnet && \
- curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash && \
- export NVM_DIR="$HOME/.nvm" && \
- [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
- nvm install v16.16.0 && \
- nvm use v16.16.0
-
-RUN git clone https://github.com/uniquenetwork/polkadot-launch -b $POLKADOT_LAUNCH_BRANCH
-
-RUN export NVM_DIR="$HOME/.nvm" && \
- [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
- cd /polkadot-launch && \
- npm install --global yarn && \
- yarn install
-
-COPY --from=builder-unique /unique_parachain/unique-chain/target/release/unique-collator /unique-chain/target/release/
-COPY --from=builder-polkadot /unique_parachain/polkadot/target/release/polkadot /polkadot/target/release/
-COPY --from=builder-moonbeam /unique_parachain/moonbeam/target/release/moonbeam /moonbeam/target/release/
-COPY --from=builder-cumulus /unique_parachain/cumulus/target/release/polkadot-parachain /cumulus/target/release/cumulus
-COPY --from=builder-acala /unique_parachain/Acala/target/production/acala /acala/target/release/
-COPY --from=builder-chainql /chainql/target/release/chainql /chainql/target/release/
-
-EXPOSE 9844
-EXPOSE 9944
-EXPOSE 9946
-EXPOSE 9947
-EXPOSE 9948
-
-CMD export NVM_DIR="$HOME/.nvm" PATH="$PATH:/chainql/target/release" && \
- [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
- cd /polkadot-launch && \
- yarn start launch-config.json
.docker/docker-compose-testnet.ymldiffbeforeafterboth--- a/.docker/docker-compose-testnet.yml
+++ /dev/null
@@ -1,17 +0,0 @@
-version: "3.5"
-
-services:
- xcm_nodes:
- build:
- context: ../
- dockerfile: .docker/Dockerfile-testnet
- expose:
- - 9844
- - 9944
- ports:
- - 127.0.0.1:9844:9844
- - 127.0.0.1:9944:9944
- logging:
- options:
- max-size: "1m"
- max-file: "3"
.docker/docker-compose-xcm.ymldiffbeforeafterboth--- a/.docker/docker-compose-xcm.yml
+++ /dev/null
@@ -1,23 +0,0 @@
-version: "3.5"
-
-services:
- xcm_nodes:
- build:
- context: ../
- dockerfile: .docker/Dockerfile-xcm
- expose:
- - 9844
- - 9944
- - 9946
- - 9947
- - 9948
- ports:
- - 127.0.0.1:9844:9844
- - 127.0.0.1:9944:9944
- - 127.0.0.1:9946:9946
- - 127.0.0.1:9947:9947
- - 127.0.0.1:9948:9948
- logging:
- options:
- max-size: "1m"
- max-file: "3"
.docker/docker-compose.tmp-testnet.j2diffbeforeafterboth--- a/.docker/docker-compose.tmp-testnet.j2
+++ /dev/null
@@ -1,18 +0,0 @@
-version: "3.5"
-
-services:
- xcm_nodes:
- build:
- args:
- - "RUST_TOOLCHAIN={{ RUST_TOOLCHAIN }}"
- - "BRANCH={{ BRANCH }}"
- - "FEATURE={{ FEATURE }}"
- - "POLKADOT_BUILD_BRANCH={{ POLKADOT_BUILD_BRANCH }}"
- - "POLKADOT_LAUNCH_BRANCH={{ POLKADOT_LAUNCH_BRANCH }}"
- image: testnet_node_{{ NETWORK }}
- container_name: testnet_node_{{ NETWORK }}
- volumes:
- - type: bind
- source: ./testnet-config/launch-config-testnet.json
- target: /polkadot-launch/launch-config.json
- read_only: true
.docker/docker-compose.tmp-xcm-quartz.ymldiffbeforeafterboth--- a/.docker/docker-compose.tmp-xcm-quartz.yml
+++ /dev/null
@@ -1,25 +0,0 @@
-version: "3.5"
-
-services:
- xcm_nodes:
- build:
- args:
- - "RUST_TOOLCHAIN=nightly-2022-07-24"
- - "BRANCH=release-v927020"
- - "FEATURE=quartz-runtime"
- - "POLKADOT_BUILD_BRANCH=release-v0.9.27"
- - "ACALA_BUILD_BRANCH=2.9.0"
- - "MOONBEAM_BUILD_BRANCH=v0.25.0"
- - "CUMULUS_BUILD_BRANCH=release-v0.9.230"
- - "POLKADOT_LAUNCH_BRANCH=feature/rewrite-chain-id-in-spec"
- image: xcm_nodes_quartz
- container_name: xcm_nodes_quartz
- volumes:
- - type: bind
- source: ./xcm-config/launch-config-xcm-quartz.json
- target: /polkadot-launch/launch-config.json
- read_only: true
- - type: bind
- source: ./xcm-config/5validators.jsonnet
- target: /polkadot-launch/5validators.jsonnet
- read_only: true
.docker/docker-compose.tmp-xcm-unique.ymldiffbeforeafterboth--- a/.docker/docker-compose.tmp-xcm-unique.yml
+++ /dev/null
@@ -1,27 +0,0 @@
-version: "3.5"
-
-services:
- xcm_nodes:
- build:
- args:
- - "RUST_TOOLCHAIN=nightly-2022-07-24"
- - "BRANCH=release-v927020"
- - "REPO_URL=https://github.com/UniqueNetwork/unique-chain.git"
- - "FEATURE=unique-runtime"
- - "POLKADOT_BUILD_BRANCH=release-v0.9.27"
- - "ACALA_BUILD_BRANCH=2.9.0"
- - "MOONBEAM_BUILD_BRANCH=v0.25.0"
- - "CUMULUS_BUILD_BRANCH=release-v0.9.230"
- - "POLKADOT_LAUNCH_BRANCH=feature/rewrite-chain-id-in-spec"
- image: xcm_nodes_unique
- container_name: xcm_nodes_unique
- volumes:
- - type: bind
- source: ./xcm-config/launch-config-xcm-unique.json
- target: /polkadot-launch/launch-config.json
- read_only: true
- - type: bind
- source: ./xcm-config/5validators.jsonnet
- target: /polkadot-launch/5validators.jsonnet
- read_only: true
-
.docker/docker-compose.tmp-xcm.j2diffbeforeafterboth--- a/.docker/docker-compose.tmp-xcm.j2
+++ /dev/null
@@ -1,21 +0,0 @@
-version: "3.5"
-
-services:
- xcm_nodes:
- build:
- args:
- - "RUST_TOOLCHAIN={{ RUST_TOOLCHAIN }}"
- - "BRANCH={{ BRANCH }}"
- - "FEATURE={{ FEATURE }}"
- - "POLKADOT_BUILD_BRANCH={{ POLKADOT_BUILD_BRANCH }}"
- - "ACALA_BUILD_BRANCH={{ ACALA_BUILD_BRANCH }}"
- - "MOONBEAM_BUILD_BRANCH={{ MOONBEAM_BUILD_BRANCH }}"
- - "CUMULUS_BUILD_BRANCH={{ CUMULUS_BUILD_BRANCH }}"
- - "POLKADOT_LAUNCH_BRANCH={{ POLKADOT_LAUNCH_BRANCH }}"
- image: xcm_nodes_{{ NETWORK }}
- container_name: xcm_nodes_{{ NETWORK }}
- volumes:
- - type: bind
- source: ./xcm-config/launch-config-xcm-{{ NETWORK }}.json
- target: /polkadot-launch/launch-config.json
- read_only: true
.docker/testnet-config/launch-config-testnet.jsondiffbeforeafterboth--- a/.docker/testnet-config/launch-config-testnet.json
+++ /dev/null
@@ -1,121 +0,0 @@
-{
- "relaychain": {
- "bin": "../polkadot/target/release/polkadot",
- "chain": "rococo-local",
- "nodes": [
- {
- "name": "alice",
- "wsPort": 9844,
- "rpcPort": 9843,
- "port": 30444,
- "flags": [
- "-lparachain::candidate_validation=debug",
- "-lxcm=trace",
- "--rpc-cors=all",
- "--unsafe-rpc-external",
- "--unsafe-ws-external"
- ]
- },
- {
- "name": "bob",
- "wsPort": 9855,
- "rpcPort": 9854,
- "port": 30555,
- "flags": [
- "-lparachain::candidate_validation=debug",
- "-lxcm=trace",
- "--rpc-cors=all",
- "--unsafe-rpc-external",
- "--unsafe-ws-external"
- ]
- },
- {
- "name": "charlie",
- "wsPort": 9866,
- "rpcPort": 9865,
- "port": 30666,
- "flags": [
- "-lparachain::candidate_validation=debug",
- "-lxcm=trace",
- "--rpc-cors=all",
- "--unsafe-rpc-external",
- "--unsafe-ws-external"
- ]
- },
- {
- "name": "dave",
- "wsPort": 9877,
- "rpcPort": 9876,
- "port": 30777,
- "flags": [
- "-lparachain::candidate_validation=debug",
- "-lxcm=trace",
- "--rpc-cors=all",
- "--unsafe-rpc-external",
- "--unsafe-ws-external"
- ]
- },
- {
- "name": "eve",
- "wsPort": 9888,
- "rpcPort": 9887,
- "port": 30888,
- "flags": [
- "-lparachain::candidate_validation=debug",
- "-lxcm=trace",
- "--rpc-cors=all",
- "--unsafe-rpc-external",
- "--unsafe-ws-external"
- ]
- }
- ],
- "genesis": {
- "runtime": {
- "runtime_genesis_config": {
- "parachainsConfiguration": {
- "config": {
- "validation_upgrade_frequency": 1,
- "validation_upgrade_delay": 1
- }
- }
- }
- }
- }
- },
- "parachains": [
- {
- "bin": "../unique-chain/target/release/unique-collator",
- "id": "1000",
- "balance": "1000000000000000000000000",
- "nodes": [
- {
- "port": 31200,
- "wsPort": 9944,
- "rpcPort": 9933,
- "name": "alice",
- "flags": [
- "--rpc-cors=all",
- "--unsafe-rpc-external",
- "--unsafe-ws-external",
- "-lxcm=trace"
- ]
- },
- {
- "port": 31201,
- "wsPort": 9945,
- "rpcPort": 9934,
- "name": "bob",
- "flags": [
- "--rpc-cors=all",
- "--unsafe-rpc-external",
- "--unsafe-ws-external",
- "-lxcm=trace"
- ]
- }
- ]
- }
- ],
- "simpleParachains": [],
- "hrmpChannels": [],
- "finalization": false
-}
.github/workflows/xcm-testnet-build.ymldiffbeforeafterboth1name: xcm-testnet-build23# Controls when the action will run.4on:5 workflow_call:6 7 # Allows you to run this workflow manually from the Actions tab8 workflow_dispatch:910#Define Workflow variables11env:12 REPO_URL: ${{ github.server_url }}/${{ github.repository }}1314# A workflow run is made up of one or more jobs that can run sequentially or in parallel15jobs:1617 prepare-execution-marix:1819 name: Prepare execution matrix2021 runs-on: [XL]22 outputs:23 matrix: ${{ steps.create_matrix.outputs.matrix }}2425 steps:2627 - name: Clean Workspace28 uses: AutoModality/action-clean@v1.1.02930 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it31 - uses: actions/checkout@v332 with:33 ref: ${{ github.head_ref }} #Checking out head commit3435 - name: Read .env file36 uses: xom9ikk/dotenv@v1.0.23738 - name: Create Execution matrix39 uses: fabiocaccamo/create-matrix-action@v240 id: create_matrix41 with:42 matrix: |43 network {opal}, runtime {opal}, features {opal-runtime}, acala_version {${{ env.ACALA_BUILD_BRANCH }}}, moonbeam_version {${{ env.MOONBEAM_BUILD_BRANCH }}}, cumulus_version {${{ env.WESTMINT_BUILD_BRANCH }}}44 network {quartz}, runtime {quartz}, features {quartz-runtime}, acala_version {${{ env.KARURA_BUILD_BRANCH }}}, moonbeam_version {${{ env.MOONRIVER_BUILD_BRANCH }}}, cumulus_version {${{ env.STATEMINE_BUILD_BRANCH }}}45 network {unique}, runtime {unique}, features {unique-runtime}, acala_version {${{ env.ACALA_BUILD_BRANCH }}}, moonbeam_version {${{ env.MOONBEAM_BUILD_BRANCH }}}, cumulus_version {${{ env.STATEMINT_BUILD_BRANCH }}}4647 xcm-build:48 49 needs: prepare-execution-marix50 # The type of runner that the job will run on51 runs-on: [XL]5253 timeout-minutes: 6005455 name: ${{ matrix.network }}5657 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.5859 strategy:60 matrix:61 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}6263 steps:64 - name: Skip if pull request is in Draft65 if: github.event.pull_request.draft == true66 run: exit 16768 - name: Clean Workspace69 uses: AutoModality/action-clean@v1.1.07071 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it72 - uses: actions/checkout@v373 with:74 ref: ${{ github.head_ref }} #Checking out head commit7576 - name: Read .env file77 uses: xom9ikk/dotenv@v1.0.27879 - name: Log in to Docker Hub80 uses: docker/login-action@v2.0.081 with:82 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}83 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}8485 - name: Install jq86 run: sudo apt install jq -y8788 # - name: Get autorization token from DOCKERHUB89 # run: | 90 # # aquire token91 # TOKEN=$(curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${{ secrets.CORE_DOCKERHUB_USERNAME }}'", "password": "'${{ secrets.CORE_DOCKERHUB_TOKEN }}'"}' https://hub.docker.com/v2/users/login/ | jq -r .token)92 # export TOKEN=$TOKEN9394 # Check POLKADOT version and build it if it doesn't exist in repository95 - name: Generate ENV related extend Dockerfile file for POLKADOT96 uses: cuchi/jinja2-action@v1.2.097 with:98 template: .docker/Dockerfile-polkadot.j299 output_file: .docker/Dockerfile-polkadot.${{ env.POLKADOT_BUILD_BRANCH }}.yml100 variables: |101 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}102 POLKADOT_BUILD_BRANCH=${{ env.POLKADOT_BUILD_BRANCH }}103104 - name: Check if the dockerhub repository contains the needed version POLKADOT105 run: |106 # aquire token107 TOKEN=$(curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${{ secrets.CORE_DOCKERHUB_USERNAME }}'", "password": "'${{ secrets.CORE_DOCKERHUB_TOKEN }}'"}' https://hub.docker.com/v2/users/login/ | jq -r .token)108 export TOKEN=$TOKEN109110 # Get TAGS from DOCKERHUB POLKADOT repository111 POLKADOT_TAGS=$(curl -s -H "Authorization: JWT ${TOKEN}" https://hub.docker.com/v2/repositories/uniquenetwork/builder-polkadot/tags/?page_size=100 | jq -r '."results"[]["name"]')112 # Show TAGS113 echo "POLKADOT TAGS:"114 echo $POLKADOT_TAGS115 # Check correct version POLKADOT and build it if it doesn't exist in POLKADOT TAGS116 if [[ ${POLKADOT_TAGS[*]} =~ (^|[[:space:]])"${{ env.POLKADOT_BUILD_BRANCH }}"($|[[:space:]]) ]]; then117 echo "Repository has needed POLKADOT version";118 docker pull uniquenetwork/builder-polkadot:${{ env.POLKADOT_BUILD_BRANCH }}119 else120 echo "Repository has not needed POLKADOT version, so build it";121 cd .docker/ && docker build --no-cache --file ./Dockerfile-polkadot.${{ env.POLKADOT_BUILD_BRANCH }}.yml --tag uniquenetwork/builder-polkadot:${{ env.POLKADOT_BUILD_BRANCH }} .122 echo "Push needed POLKADOT version to the repository";123 docker push uniquenetwork/builder-polkadot:${{ env.POLKADOT_BUILD_BRANCH }}124 fi125 shell: bash126127 # Check ACALA version and build it if it doesn't exist in repository128 - name: Generate ENV related extend Dockerfile file for ACALA129 uses: cuchi/jinja2-action@v1.2.0130 with:131 template: .docker/Dockerfile-acala.j2132 output_file: .docker/Dockerfile-acala.${{ matrix.acala_version }}.yml133 variables: |134 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}135 ACALA_BUILD_BRANCH=${{ matrix.acala_version }}136137 - name: Check if the dockerhub repository contains the needed ACALA version138 run: |139 # aquire token140 TOKEN=$(curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${{ secrets.CORE_DOCKERHUB_USERNAME }}'", "password": "'${{ secrets.CORE_DOCKERHUB_TOKEN }}'"}' https://hub.docker.com/v2/users/login/ | jq -r .token)141 export TOKEN=$TOKEN142143 # Get TAGS from DOCKERHUB repository144 ACALA_TAGS=$(curl -s -H "Authorization: JWT ${TOKEN}" https://hub.docker.com/v2/repositories/uniquenetwork/builder-acala/tags/?page_size=100 | jq -r '."results"[]["name"]')145 # Show TAGS146 echo "ACALA TAGS:"147 echo $ACALA_TAGS148 # Check correct version ACALA and build it if it doesn't exist in ACALA TAGS149 if [[ ${ACALA_TAGS[*]} =~ (^|[[:space:]])"${{ matrix.acala_version }}"($|[[:space:]]) ]]; then150 echo "Repository has needed ACALA version";151 docker pull uniquenetwork/builder-acala:${{ matrix.acala_version }}152 else153 echo "Repository has not needed ACALA version, so build it";154 cd .docker/ && docker build --no-cache --file ./Dockerfile-acala.${{ matrix.acala_version }}.yml --tag uniquenetwork/builder-acala:${{ matrix.acala_version }} .155 echo "Push needed ACALA version to the repository";156 docker push uniquenetwork/builder-acala:${{ matrix.acala_version }}157 fi158 shell: bash159160 # Check MOONBEAM version and build it if it doesn't exist in repository161 - name: Generate ENV related extend Dockerfile file for MOONBEAM162 uses: cuchi/jinja2-action@v1.2.0163 with:164 template: .docker/Dockerfile-moonbeam.j2165 output_file: .docker/Dockerfile-moonbeam.${{ matrix.moonbeam_version }}.yml166 variables: |167 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}168 MOONBEAM_BUILD_BRANCH=${{ matrix.moonbeam_version }}169170 - name: Check if the dockerhub repository contains the needed MOONBEAM version171 run: |172 # aquire token173 TOKEN=$(curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${{ secrets.CORE_DOCKERHUB_USERNAME }}'", "password": "'${{ secrets.CORE_DOCKERHUB_TOKEN }}'"}' https://hub.docker.com/v2/users/login/ | jq -r .token)174 export TOKEN=$TOKEN175176 # Get TAGS from DOCKERHUB repository177 MOONBEAM_TAGS=$(curl -s -H "Authorization: JWT ${TOKEN}" https://hub.docker.com/v2/repositories/uniquenetwork/builder-moonbeam/tags/?page_size=100 | jq -r '."results"[]["name"]')178 # Show TAGS179 echo "MOONBEAM TAGS:"180 echo $MOONBEAM_TAGS181 # Check correct version MOONBEAM and build it if it doesn't exist in MOONBEAM TAGS182 if [[ ${MOONBEAM_TAGS[*]} =~ (^|[[:space:]])"${{ matrix.moonbeam_version }}"($|[[:space:]]) ]]; then183 echo "Repository has needed MOONBEAM version";184 docker pull uniquenetwork/builder-moonbeam:${{ matrix.moonbeam_version }}185 else186 echo "Repository has not needed MOONBEAM version, so build it";187 cd .docker/ && docker build --no-cache --file ./Dockerfile-moonbeam.${{ matrix.moonbeam_version }}.yml --tag uniquenetwork/builder-moonbeam:${{ matrix.moonbeam_version }} .188 echo "Push needed MOONBEAM version to the repository";189 docker push uniquenetwork/builder-moonbeam:${{ matrix.moonbeam_version }}190 fi191 shell: bash192193194 # Check CUMULUS version and build it if it doesn't exist in repository195 - name: Generate ENV related extend Dockerfile file for CUMULUS196 uses: cuchi/jinja2-action@v1.2.0197 with:198 template: .docker/Dockerfile-cumulus.j2199 output_file: .docker/Dockerfile-cumulus.${{ matrix.cumulus_version }}.yml200 variables: |201 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}202 CUMULUS_BUILD_BRANCH=${{ matrix.cumulus_version }}203204 - name: Check if the dockerhub repository contains the needed CUMULUS version205 run: | 206 # aquire token207 TOKEN=$(curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${{ secrets.CORE_DOCKERHUB_USERNAME }}'", "password": "'${{ secrets.CORE_DOCKERHUB_TOKEN }}'"}' https://hub.docker.com/v2/users/login/ | jq -r .token)208 export TOKEN=$TOKEN209210 # Get TAGS from DOCKERHUB repository211 CUMULUS_TAGS=$(curl -s -H "Authorization: JWT ${TOKEN}" https://hub.docker.com/v2/repositories/uniquenetwork/builder-cumulus/tags/?page_size=100 | jq -r '."results"[]["name"]')212 # Show TAGS213 echo "CUMULUS TAGS:"214 echo $CUMULUS_TAGS215 # Check correct version CUMULUS and build it if it doesn't exist in CUMULUS TAGS216 if [[ ${CUMULUS_TAGS[*]} =~ (^|[[:space:]])"${{ matrix.cumulus_version }}"($|[[:space:]]) ]]; then217 echo "Repository has needed CUMULUS version";218 docker pull uniquenetwork/builder-cumulus:${{ matrix.cumulus_version }}219 else220 echo "Repository has not needed CUMULUS version, so build it";221 cd .docker/ && docker build --no-cache --file ./Dockerfile-cumulus.${{ matrix.cumulus_version }}.yml --tag uniquenetwork/builder-cumulus:${{ matrix.cumulus_version }} .222 echo "Push needed CUMULUS version to the repository";223 docker push uniquenetwork/builder-cumulus:${{ matrix.cumulus_version }}224 fi225 shell: bash226227228 # Build main image for XCM 229 - name: Generate ENV related extend Dockerfile file230 uses: cuchi/jinja2-action@v1.2.0231 with:232 template: .docker/Dockerfile-xcm.j2233 output_file: .docker/Dockerfile-xcm.${{ matrix.network }}.yml234 variables: |235 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}236 NETWORK=${{ matrix.network }}237 POLKADOT_BUILD_BRANCH=${{ env.POLKADOT_BUILD_BRANCH }}238 POLKADOT_LAUNCH_BRANCH=${{ env.POLKADOT_LAUNCH_BRANCH }}239 FEATURE=${{ matrix.features }}240 RUNTIME=${{ matrix.runtime }}241 BRANCH=${{ github.head_ref }}242 ACALA_BUILD_BRANCH=${{ matrix.acala_version }}243 MOONBEAM_BUILD_BRANCH=${{ matrix.moonbeam_version }}244 CUMULUS_BUILD_BRANCH=${{ matrix.cumulus_version }}245246 - name: Show build Dockerfile247 run: cat .docker/Dockerfile-xcm.${{ matrix.network }}.yml248249 - name: Show launch-config-xcm-${{ matrix.network }} configuration250 run: cat .docker/xcm-config/launch-config-xcm-${{ matrix.network }}.json251252 - name: Run find-and-replace to remove slashes from branch name253 uses: mad9000/actions-find-and-replace-string@2254 id: branchname255 with:256 source: ${{ github.head_ref }}257 find: '/'258 replace: '-'259260 - name: Pull chainql docker image261 run: docker pull uniquenetwork/builder-chainql:latest262263 - name: Build the stack264 run: cd .docker/ && docker build --no-cache --file ./Dockerfile-xcm.${{ matrix.network }}.yml --tag uniquenetwork/xcm-${{ matrix.network }}-testnet-local:nightly-${{ steps.branchname.outputs.value }}-${{ github.sha }} --tag uniquenetwork/xcm-${{ matrix.network }}-testnet-local:latest .265266 - name: Push docker image version267 run: docker push uniquenetwork/xcm-${{ matrix.network }}-testnet-local:nightly-${{ steps.branchname.outputs.value }}-${{ github.sha }}268269 - name: Push docker image latest270 run: docker push uniquenetwork/xcm-${{ matrix.network }}-testnet-local:latest271272 - name: Clean Workspace273 if: always()274 uses: AutoModality/action-clean@v1.1.0275276 - name: Remove builder cache277 if: always() # run this step always278 run: |279 docker builder prune -f280 docker system prune -f2812822831name: xcm-testnet-build23# Controls when the action will run.4on:5 workflow_call:6 7 # Allows you to run this workflow manually from the Actions tab8 workflow_dispatch:910#Define Workflow variables11env:12 REPO_URL: ${{ github.server_url }}/${{ github.repository }}1314# A workflow run is made up of one or more jobs that can run sequentially or in parallel15jobs:1617 prepare-execution-marix:1819 name: Prepare execution matrix2021 runs-on: [XL]22 outputs:23 matrix: ${{ steps.create_matrix.outputs.matrix }}2425 steps:2627 - name: Clean Workspace28 uses: AutoModality/action-clean@v1.1.02930 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it31 - uses: actions/checkout@v332 with:33 ref: ${{ github.head_ref }} #Checking out head commit3435 - name: Read .env file36 uses: xom9ikk/dotenv@v1.0.23738 - name: Create Execution matrix39 uses: fabiocaccamo/create-matrix-action@v240 id: create_matrix41 with:42 matrix: |43 network {opal}, runtime {opal}, features {opal-runtime}, acala_version {${{ env.ACALA_BUILD_BRANCH }}}, moonbeam_version {${{ env.MOONBEAM_BUILD_BRANCH }}}, cumulus_version {${{ env.WESTMINT_BUILD_BRANCH }}}44 network {quartz}, runtime {quartz}, features {quartz-runtime}, acala_version {${{ env.KARURA_BUILD_BRANCH }}}, moonbeam_version {${{ env.MOONRIVER_BUILD_BRANCH }}}, cumulus_version {${{ env.STATEMINE_BUILD_BRANCH }}}45 network {unique}, runtime {unique}, features {unique-runtime}, acala_version {${{ env.ACALA_BUILD_BRANCH }}}, moonbeam_version {${{ env.MOONBEAM_BUILD_BRANCH }}}, cumulus_version {${{ env.STATEMINT_BUILD_BRANCH }}}4647 xcm-build:48 49 needs: prepare-execution-marix50 # The type of runner that the job will run on51 runs-on: [XL]5253 timeout-minutes: 6005455 name: ${{ matrix.network }}5657 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.5859 strategy:60 matrix:61 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}6263 steps:64 - name: Skip if pull request is in Draft65 if: github.event.pull_request.draft == true66 run: exit 16768 - name: Clean Workspace69 uses: AutoModality/action-clean@v1.1.07071 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it72 - uses: actions/checkout@v373 with:74 ref: ${{ github.head_ref }} #Checking out head commit7576 - name: Read .env file77 uses: xom9ikk/dotenv@v1.0.27879 - name: Log in to Docker Hub80 uses: docker/login-action@v2.0.081 with:82 username: ${{ secrets.CORE_DOCKERHUB_USERNAME }}83 password: ${{ secrets.CORE_DOCKERHUB_TOKEN }}8485 - name: Install jq86 run: sudo apt install jq -y8788 # Check POLKADOT version and build it if it doesn't exist in repository89 - name: Generate ENV related extend Dockerfile file for POLKADOT90 uses: cuchi/jinja2-action@v1.2.091 with:92 template: .docker/Dockerfile-polkadot.j293 output_file: .docker/Dockerfile-polkadot.${{ env.POLKADOT_BUILD_BRANCH }}.yml94 variables: |95 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}96 POLKADOT_BUILD_BRANCH=${{ env.POLKADOT_BUILD_BRANCH }}9798 - name: Check if the dockerhub repository contains the needed version POLKADOT99 run: |100 # aquire token101 TOKEN=$(curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${{ secrets.CORE_DOCKERHUB_USERNAME }}'", "password": "'${{ secrets.CORE_DOCKERHUB_TOKEN }}'"}' https://hub.docker.com/v2/users/login/ | jq -r .token)102 export TOKEN=$TOKEN103104 # Get TAGS from DOCKERHUB POLKADOT repository105 POLKADOT_TAGS=$(curl -s -H "Authorization: JWT ${TOKEN}" https://hub.docker.com/v2/repositories/uniquenetwork/builder-polkadot/tags/?page_size=100 | jq -r '."results"[]["name"]')106 # Show TAGS107 echo "POLKADOT TAGS:"108 echo $POLKADOT_TAGS109 # Check correct version POLKADOT and build it if it doesn't exist in POLKADOT TAGS110 if [[ ${POLKADOT_TAGS[*]} =~ (^|[[:space:]])"${{ env.POLKADOT_BUILD_BRANCH }}"($|[[:space:]]) ]]; then111 echo "Repository has needed POLKADOT version";112 docker pull uniquenetwork/builder-polkadot:${{ env.POLKADOT_BUILD_BRANCH }}113 else114 echo "Repository has not needed POLKADOT version, so build it";115 cd .docker/ && docker build --no-cache --file ./Dockerfile-polkadot.${{ env.POLKADOT_BUILD_BRANCH }}.yml --tag uniquenetwork/builder-polkadot:${{ env.POLKADOT_BUILD_BRANCH }} .116 echo "Push needed POLKADOT version to the repository";117 docker push uniquenetwork/builder-polkadot:${{ env.POLKADOT_BUILD_BRANCH }}118 fi119 shell: bash120121 # Check ACALA version and build it if it doesn't exist in repository122 - name: Generate ENV related extend Dockerfile file for ACALA123 uses: cuchi/jinja2-action@v1.2.0124 with:125 template: .docker/Dockerfile-acala.j2126 output_file: .docker/Dockerfile-acala.${{ matrix.acala_version }}.yml127 variables: |128 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}129 ACALA_BUILD_BRANCH=${{ matrix.acala_version }}130131 - name: Check if the dockerhub repository contains the needed ACALA version132 run: |133 # aquire token134 TOKEN=$(curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${{ secrets.CORE_DOCKERHUB_USERNAME }}'", "password": "'${{ secrets.CORE_DOCKERHUB_TOKEN }}'"}' https://hub.docker.com/v2/users/login/ | jq -r .token)135 export TOKEN=$TOKEN136137 # Get TAGS from DOCKERHUB repository138 ACALA_TAGS=$(curl -s -H "Authorization: JWT ${TOKEN}" https://hub.docker.com/v2/repositories/uniquenetwork/builder-acala/tags/?page_size=100 | jq -r '."results"[]["name"]')139 # Show TAGS140 echo "ACALA TAGS:"141 echo $ACALA_TAGS142 # Check correct version ACALA and build it if it doesn't exist in ACALA TAGS143 if [[ ${ACALA_TAGS[*]} =~ (^|[[:space:]])"${{ matrix.acala_version }}"($|[[:space:]]) ]]; then144 echo "Repository has needed ACALA version";145 docker pull uniquenetwork/builder-acala:${{ matrix.acala_version }}146 else147 echo "Repository has not needed ACALA version, so build it";148 cd .docker/ && docker build --no-cache --file ./Dockerfile-acala.${{ matrix.acala_version }}.yml --tag uniquenetwork/builder-acala:${{ matrix.acala_version }} .149 echo "Push needed ACALA version to the repository";150 docker push uniquenetwork/builder-acala:${{ matrix.acala_version }}151 fi152 shell: bash153154 # Check MOONBEAM version and build it if it doesn't exist in repository155 - name: Generate ENV related extend Dockerfile file for MOONBEAM156 uses: cuchi/jinja2-action@v1.2.0157 with:158 template: .docker/Dockerfile-moonbeam.j2159 output_file: .docker/Dockerfile-moonbeam.${{ matrix.moonbeam_version }}.yml160 variables: |161 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}162 MOONBEAM_BUILD_BRANCH=${{ matrix.moonbeam_version }}163164 - name: Check if the dockerhub repository contains the needed MOONBEAM version165 run: |166 # aquire token167 TOKEN=$(curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${{ secrets.CORE_DOCKERHUB_USERNAME }}'", "password": "'${{ secrets.CORE_DOCKERHUB_TOKEN }}'"}' https://hub.docker.com/v2/users/login/ | jq -r .token)168 export TOKEN=$TOKEN169170 # Get TAGS from DOCKERHUB repository171 MOONBEAM_TAGS=$(curl -s -H "Authorization: JWT ${TOKEN}" https://hub.docker.com/v2/repositories/uniquenetwork/builder-moonbeam/tags/?page_size=100 | jq -r '."results"[]["name"]')172 # Show TAGS173 echo "MOONBEAM TAGS:"174 echo $MOONBEAM_TAGS175 # Check correct version MOONBEAM and build it if it doesn't exist in MOONBEAM TAGS176 if [[ ${MOONBEAM_TAGS[*]} =~ (^|[[:space:]])"${{ matrix.moonbeam_version }}"($|[[:space:]]) ]]; then177 echo "Repository has needed MOONBEAM version";178 docker pull uniquenetwork/builder-moonbeam:${{ matrix.moonbeam_version }}179 else180 echo "Repository has not needed MOONBEAM version, so build it";181 cd .docker/ && docker build --no-cache --file ./Dockerfile-moonbeam.${{ matrix.moonbeam_version }}.yml --tag uniquenetwork/builder-moonbeam:${{ matrix.moonbeam_version }} .182 echo "Push needed MOONBEAM version to the repository";183 docker push uniquenetwork/builder-moonbeam:${{ matrix.moonbeam_version }}184 fi185 shell: bash186187188 # Check CUMULUS version and build it if it doesn't exist in repository189 - name: Generate ENV related extend Dockerfile file for CUMULUS190 uses: cuchi/jinja2-action@v1.2.0191 with:192 template: .docker/Dockerfile-cumulus.j2193 output_file: .docker/Dockerfile-cumulus.${{ matrix.cumulus_version }}.yml194 variables: |195 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}196 CUMULUS_BUILD_BRANCH=${{ matrix.cumulus_version }}197198 - name: Check if the dockerhub repository contains the needed CUMULUS version199 run: | 200 # aquire token201 TOKEN=$(curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${{ secrets.CORE_DOCKERHUB_USERNAME }}'", "password": "'${{ secrets.CORE_DOCKERHUB_TOKEN }}'"}' https://hub.docker.com/v2/users/login/ | jq -r .token)202 export TOKEN=$TOKEN203204 # Get TAGS from DOCKERHUB repository205 CUMULUS_TAGS=$(curl -s -H "Authorization: JWT ${TOKEN}" https://hub.docker.com/v2/repositories/uniquenetwork/builder-cumulus/tags/?page_size=100 | jq -r '."results"[]["name"]')206 # Show TAGS207 echo "CUMULUS TAGS:"208 echo $CUMULUS_TAGS209 # Check correct version CUMULUS and build it if it doesn't exist in CUMULUS TAGS210 if [[ ${CUMULUS_TAGS[*]} =~ (^|[[:space:]])"${{ matrix.cumulus_version }}"($|[[:space:]]) ]]; then211 echo "Repository has needed CUMULUS version";212 docker pull uniquenetwork/builder-cumulus:${{ matrix.cumulus_version }}213 else214 echo "Repository has not needed CUMULUS version, so build it";215 cd .docker/ && docker build --no-cache --file ./Dockerfile-cumulus.${{ matrix.cumulus_version }}.yml --tag uniquenetwork/builder-cumulus:${{ matrix.cumulus_version }} .216 echo "Push needed CUMULUS version to the repository";217 docker push uniquenetwork/builder-cumulus:${{ matrix.cumulus_version }}218 fi219 shell: bash220221222 # Build main image for XCM 223 - name: Generate ENV related extend Dockerfile file224 uses: cuchi/jinja2-action@v1.2.0225 with:226 template: .docker/Dockerfile-xcm.j2227 output_file: .docker/Dockerfile-xcm.${{ matrix.network }}.yml228 variables: |229 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}230 NETWORK=${{ matrix.network }}231 POLKADOT_BUILD_BRANCH=${{ env.POLKADOT_BUILD_BRANCH }}232 POLKADOT_LAUNCH_BRANCH=${{ env.POLKADOT_LAUNCH_BRANCH }}233 FEATURE=${{ matrix.features }}234 RUNTIME=${{ matrix.runtime }}235 BRANCH=${{ github.head_ref }}236 ACALA_BUILD_BRANCH=${{ matrix.acala_version }}237 MOONBEAM_BUILD_BRANCH=${{ matrix.moonbeam_version }}238 CUMULUS_BUILD_BRANCH=${{ matrix.cumulus_version }}239240 - name: Show build Dockerfile241 run: cat .docker/Dockerfile-xcm.${{ matrix.network }}.yml242243 - name: Show launch-config-xcm-${{ matrix.network }} configuration244 run: cat .docker/xcm-config/launch-config-xcm-${{ matrix.network }}.json245246 - name: Run find-and-replace to remove slashes from branch name247 uses: mad9000/actions-find-and-replace-string@2248 id: branchname249 with:250 source: ${{ github.head_ref }}251 find: '/'252 replace: '-'253254 - name: Pull chainql docker image255 run: docker pull uniquenetwork/builder-chainql:latest256257 - name: Build the stack258 run: cd .docker/ && docker build --no-cache --file ./Dockerfile-xcm.${{ matrix.network }}.yml --tag uniquenetwork/xcm-${{ matrix.network }}-testnet-local:nightly-${{ steps.branchname.outputs.value }}-${{ github.sha }} --tag uniquenetwork/xcm-${{ matrix.network }}-testnet-local:latest .259260 - name: Push docker image version261 run: docker push uniquenetwork/xcm-${{ matrix.network }}-testnet-local:nightly-${{ steps.branchname.outputs.value }}-${{ github.sha }}262263 - name: Push docker image latest264 run: docker push uniquenetwork/xcm-${{ matrix.network }}-testnet-local:latest265266 - name: Clean Workspace267 if: always()268 uses: AutoModality/action-clean@v1.1.0269270 - name: Remove builder cache271 if: always() # run this step always272 run: |273 docker builder prune -f274 docker system prune -f275276277