git.delta.rocks / unique-network / refs/commits / 4f6ef612fc53

difftreelog

Merge branch 'develop' into CI-43-try-runtime

Alexander Aksenov2022-08-18parents: #d49036f #032326e.patch.diff
in: master

10 files changed

modified.docker/Dockerfile-try-runtimediffbeforeafterboth
--- a/.docker/Dockerfile-try-runtime
+++ b/.docker/Dockerfile-try-runtime
@@ -34,17 +34,12 @@
 
 ARG PROFILE=release
 ARG FEATURE=
-ARG REPO_URL=
-ARG BRANCH=
 ARG FORK_FROM=
 
+COPY . /unique_parachain
 WORKDIR /unique_parachain
 
 
 RUN echo "Requested features: $FEATURE\n" && \
     echo "Fork from: $FORK_FROM\n" && \
-    echo "Repositry URL: $REPO_URL\n" && \
-    echo "Branch: $BRANCH\n" && \
-    git clone $REPO_URL -b $BRANCH . && \
     cargo run --features=$FEATURE --release -- try-runtime on-runtime-upgrade live --uri $FORK_FROM
- 
\ No newline at end of file
modified.docker/docker-compose.try-runtime.j2diffbeforeafterboth
--- a/.docker/docker-compose.try-runtime.j2
+++ b/.docker/docker-compose.try-runtime.j2
@@ -5,8 +5,6 @@
     build:
       args:
         - "RUST_TOOLCHAIN={{ RUST_TOOLCHAIN }}"
-        - "BRANCH={{ BRANCH }}"
-        - "REPO_URL={{ REPO_URL }}"
         - "FEATURE={{ FEATURE }}"
         - "FORK_FROM={{ FORK_FROM }}"
 
modified.github/workflows/build-test-master.ymldiffbeforeafterboth
--- a/.github/workflows/build-test-master.yml
+++ b/.github/workflows/build-test-master.yml
@@ -1,4 +1,4 @@
-name: MASTER - Build & Test
+name: Yarn test para
 
 # Controls when the action will run.
 on:
@@ -19,15 +19,19 @@
 env:
   REPO_URL: ${{ github.server_url }}/${{ github.repository }}
 
+concurrency: 
+  group: ${{ github.workflow }}-${{ github.ref }}
+  cancel-in-progress: true
+
 # A workflow run is made up of one or more jobs that can run sequentially or in parallel
 jobs:
 
   master-build-and-test:
     # The type of runner that the job will run on
-    runs-on: self-hosted-ci
+    runs-on: [self-hosted-ci,large]
+    timeout-minutes: 1380
 
-
-    name: ${{ matrix.network }} - Build and Test
+    name: ${{ matrix.network }}
 
     continue-on-error: true         #Do not stop testing of matrix runs failed.
 
modified.github/workflows/codestyle.ymldiffbeforeafterboth
--- a/.github/workflows/codestyle.yml
+++ b/.github/workflows/codestyle.yml
@@ -10,6 +10,10 @@
       - synchronize
       - ready_for_review
 
+concurrency: 
+  group: ${{ github.workflow }}-${{ github.ref }}
+  cancel-in-progress: true
+
 jobs:
   rustfmt:
     runs-on: self-hosted-ci
@@ -47,7 +51,7 @@
   clippy:
     if: ${{ false }}
     runs-on: self-hosted-ci
-
+      
     steps:
       - name: Skip if pull request is in Draft
         # `if: github.event.pull_request.draft == true` should be kept here, at
modified.github/workflows/fork-update-withdata.ymldiffbeforeafterboth
--- a/.github/workflows/fork-update-withdata.yml
+++ b/.github/workflows/fork-update-withdata.yml
@@ -1,4 +1,4 @@
-name: Fork Parachain update with data
+name: Upgrade replica
 
 # Controls when the action will run.
 on:
@@ -19,14 +19,19 @@
 env:
   REPO_URL: ${{ github.server_url }}/${{ github.repository }}
 
+concurrency: 
+  group: ${{ github.workflow }}-${{ github.ref }}
+  cancel-in-progress: true
+
 # A workflow run is made up of one or more jobs that can run sequentially or in parallel
 jobs:
 
   fork-update-withdata:
     # The type of runner that the job will run on
-    runs-on: self-hosted-ci
+    runs-on: [self-hosted-ci,large]
+    timeout-minutes: 1380
 
-    name: ${{ matrix.network }} Fork Parachain with data
+    name: ${{ matrix.network }}
 
     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.
 
modified.github/workflows/forkless-update-nodata.ymldiffbeforeafterboth
1name: Forkless Parachain update with no data1name: Upgrade nodata
22
3# Controls when the action will run.3# Controls when the action will run.
4on:4on:
19env:19env:
20 REPO_URL: ${{ github.server_url }}/${{ github.repository }}20 REPO_URL: ${{ github.server_url }}/${{ github.repository }}
21
22concurrency:
23 group: ${{ github.workflow }}-${{ github.ref }}
24 cancel-in-progress: true
2125
22# A workflow run is made up of one or more jobs that can run sequentially or in parallel26# A workflow run is made up of one or more jobs that can run sequentially or in parallel
23jobs:27jobs:
56 forkless-update-nodata:61 forkless-update-nodata:
57 needs: prepare-execution-marix62 needs: prepare-execution-marix
58 # The type of runner that the job will run on63 # The type of runner that the job will run on
59 runs-on: self-hosted-ci64 runs-on: [self-hosted-ci,medium]
65
66
67
68 timeout-minutes: 1380
6069
61 name: ${{ matrix.network }} - Forkless Parachain Upgrade NO data70 name: ${{ matrix.network }}
6271
63 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.72 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.
6473
modified.github/workflows/node_build_test.ymldiffbeforeafterboth
--- a/.github/workflows/node_build_test.yml
+++ b/.github/workflows/node_build_test.yml
@@ -1,4 +1,4 @@
-name: Develop - Build & test
+name: Yarn test dev
 
 # Controls when the action will run.
 on:
@@ -19,13 +19,18 @@
 env:
   REPO_URL: ${{ github.server_url }}/${{ github.repository }}
 
+concurrency: 
+  group: ${{ github.workflow }}-${{ github.ref }}
+  cancel-in-progress: true
+
 # A workflow run is made up of one or more jobs that can run sequentially or in parallel
 jobs:
   dev_build_test:
     # The type of runner that the job will run on
-    runs-on: self-hosted-ci
+    runs-on: [self-hosted-ci,medium]
+    timeout-minutes: 1380
 
-    name: Build Container, Spin it Up an test
+    name: ${{ matrix.network }}
 
     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.
 
modified.github/workflows/tests_codestyle.ymldiffbeforeafterboth
--- a/.github/workflows/tests_codestyle.yml
+++ b/.github/workflows/tests_codestyle.yml
@@ -10,6 +10,10 @@
       - synchronize
       - ready_for_review
 
+concurrency: 
+  group: ${{ github.workflow }}-${{ github.ref }}
+  cancel-in-progress: true
+
 jobs:
   code_style:
     runs-on: self-hosted-ci
modified.github/workflows/try-runtime.ymldiffbeforeafterboth
--- a/.github/workflows/try-runtime.yml
+++ b/.github/workflows/try-runtime.yml
@@ -1,4 +1,4 @@
-name: Try Runtime
+name: try-runtime
 
 # Controls when the action will run.
 on:
@@ -19,26 +19,30 @@
 env:
   REPO_URL: ${{ github.server_url }}/${{ github.repository }}
 
+concurrency: 
+  group: ${{ github.workflow }}-${{ github.ref }}
+  cancel-in-progress: true
+
 # A workflow run is made up of one or more jobs that can run sequentially or in parallel
 jobs:
   try-runtime:
     # The type of runner that the job will run on
     runs-on: self-hosted-ci
-
-    name: ${{ matrix.network }} - Try-runtime
+    
+    name: ${{ matrix.network }}
 
     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.
 
     strategy:
       matrix:
         include:
-          - network: Opal
+          - network: opal
             features: try-runtime,opal-runtime
             fork_from_address: wss://eu-ws-opal.unique.network:443
-          - network: Quartz
+          - network: quartz
             features: try-runtime,quartz-runtime
             fork_from_address: wss://eu-ws-quartz.unique.network:443
-          - network: Unique
+          - network: unique
             features: try-runtime,unique-runtime
             fork_from_address: wss://eu-ws.unique.network:443
 
@@ -79,37 +83,15 @@
           template: .docker/docker-compose.try-runtime.j2
           output_file: .docker/docker-compose.try-runtime.${{ matrix.network }}.yml
           variables: |
-            REPO_URL=${{ github.server_url }}/${{ github.repository }}.git
             RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}
             FEATURE=${{ matrix.features }}
-            BRANCH=${{ github.head_ref }}
             FORK_FROM=${{ matrix.fork_from_address }}
 
       - name: Show build configuration
         run: cat .docker/docker-compose.try-runtime.${{ matrix.network }}.yml
 
-
       - name: Build the stack
-        run: docker-compose -f ".docker/docker-compose-try-runtime.yml" -f ".docker/docker-compose.try-runtime.${{ matrix.network }}.yml" up -d --build  --force-recreate --timeout 300
-
-
-      - name: Collect Docker Logs
-        if: success() || failure()
-        uses: jwalton/gh-docker-logs@v2.2.0
-        with:
-          dest: './try-runtime-logs.${{ matrix.features }}'
-          images: 'try-runtime' 
-
-      - name: Tar logs
-        if: success() || failure()
-        run: tar cvzf ./try-runtime-logs.${{ matrix.features }}.tgz ./try-runtime-logs.${{ matrix.features }}
-
-      - name: Upload logs to GitHub
-        if: success() || failure()
-        uses: actions/upload-artifact@master
-        with:
-          name: try-runtime-logs.${{ matrix.features }}.tgz
-          path: ./try-runtime-logs.${{ matrix.features }}.tgz
+        run: docker-compose -f ".docker/docker-compose-try-runtime.yml" -f ".docker/docker-compose.try-runtime.${{ matrix.network }}.yml" up -d --build  --force-recreate --timeout 300 --remove-orphans
 
       - name: Stop running containers
         if: always()                   # run this step always
modifiednode/cli/Cargo.tomldiffbeforeafterboth
--- a/node/cli/Cargo.toml
+++ b/node/cli/Cargo.toml
@@ -266,6 +266,7 @@
 
 [dependencies.opal-runtime]
 path = '../../runtime/opal'
+optional = true
 
 [dependencies.up-data-structs]
 path = "../../primitives/data-structs"
@@ -320,11 +321,15 @@
 rmrk-rpc = { path = "../../primitives/rmrk-rpc" }
 
 [features]
-default = []
+default = ["opal-runtime"]
 runtime-benchmarks = [
     'unique-runtime?/runtime-benchmarks',
     'quartz-runtime?/runtime-benchmarks',
     'opal-runtime/runtime-benchmarks',
     'polkadot-service/runtime-benchmarks',
 ]
-try-runtime = []
+try-runtime = [
+    'unique-runtime?/try-runtime',
+    'quartz-runtime?/try-runtime',
+    'opal-runtime?/try-runtime',
+]