diff --git a/.github/workflows/build-and-upload-binaries.yml b/.github/workflows/build-upload-binaries.yml similarity index 93% rename from .github/workflows/build-and-upload-binaries.yml rename to .github/workflows/build-upload-binaries.yml index ec4366ab61..ee1271b4cd 100644 --- a/.github/workflows/build-and-upload-binaries.yml +++ b/.github/workflows/build-upload-binaries.yml @@ -1,16 +1,16 @@ -name: Build and upload binaries to artifact storage +name: build-upload-binaries on: workflow_dispatch: - inputs: + inputs: add_tokio_unstable: description: 'True to add RUSTFLAGS="--cfg tokio_unstable"' required: true default: false - type: boolean - + type: boolean + env: - NETWORK: mainnet + NETWORK: mainnet jobs: publish-nym: diff --git a/.github/workflows/ci-binary-checker.yml b/.github/workflows/ci-binary-checker.yml index 86e4903be2..ec08504816 100644 --- a/.github/workflows/ci-binary-checker.yml +++ b/.github/workflows/ci-binary-checker.yml @@ -32,7 +32,7 @@ jobs: fail-fast: false matrix: platform: [custom-linux] - + runs-on: ${{ matrix.platform }} steps: - uses: actions/checkout@v3 @@ -45,12 +45,12 @@ jobs: uses: actions-rs/toolchain@v1 with: toolchain: stable - + - name: Branch name run: echo running on branch ${GITHUB_REF##*/} - + - name: Run tests against binaries run: ./build_and_run.sh ${{ github.head_ref || github.ref_name }} working-directory: tests/ - - + + diff --git a/.github/workflows/ci-build-ts.yml b/.github/workflows/ci-build-ts.yml index 29d986f5ce..9dd6f238a2 100644 --- a/.github/workflows/ci-build-ts.yml +++ b/.github/workflows/ci-build-ts.yml @@ -1,7 +1,7 @@ name: ci-build-ts on: - push: + pull_request: paths: - "ts-packages/**" - "sdk/typescript/**" diff --git a/.github/workflows/ci-build-upload-binaries.yml b/.github/workflows/ci-build-upload-binaries.yml index d3a84b7600..168abf2837 100644 --- a/.github/workflows/ci-build-upload-binaries.yml +++ b/.github/workflows/ci-build-upload-binaries.yml @@ -2,20 +2,6 @@ name: ci-build-upload-binaries on: workflow_dispatch: - push: - paths: - - 'clients/**' - - 'common/**' - - 'explorer-api/**' - - 'gateway/**' - - 'integrations/**' - - 'mixnode/**' - - 'sdk/rust/nym-sdk/**' - - 'service-providers/**' - - 'nym-api/**' - - 'nym-outfox/**' - - 'tools/nym-cli/**' - - 'tools/ts-rs-cli/**' pull_request: paths: - 'clients/**' @@ -31,9 +17,6 @@ on: - 'tools/nym-cli/**' - 'tools/ts-rs-cli/**' -env: - NETWORK: mainnet - jobs: publish-nym: strategy: @@ -44,8 +27,6 @@ jobs: runs-on: ${{ matrix.platform }} env: CARGO_TERM_COLOR: always - # a push event from the origin repo, or a PR from external repo - if: ${{ github.event_name == 'push' || github.event.pull_request.head.repo.full_name != 'nymtech/nym' }} steps: - uses: actions/checkout@v3 @@ -59,8 +40,7 @@ jobs: echo $OUTPUT_DIR - name: Install Dependencies (Linux) - run: sudo apt-get update && sudo apt-get -y install libwebkit2gtk-4.0-dev build-essential curl wget libssl-dev libgtk-3-dev libudev-dev squashfs-tools protobuf-compiler - continue-on-error: true + run: sudo apt update && sudo apt install libudev-dev - name: Install Rust stable uses: actions-rs/toolchain@v1 diff --git a/.github/workflows/ci-build.yml b/.github/workflows/ci-build.yml index 4ad027637f..aa95bd7763 100644 --- a/.github/workflows/ci-build.yml +++ b/.github/workflows/ci-build.yml @@ -48,9 +48,6 @@ jobs: runs-on: ${{ matrix.os }} env: CARGO_TERM_COLOR: always - # Enable sccache via environment variable - # env: - # RUSTC_WRAPPER: /home/ubuntu/.cargo/bin/sccache steps: - name: Install Dependencies (Linux) run: sudo apt-get update && sudo apt-get -y install libwebkit2gtk-4.0-dev build-essential curl wget libssl-dev libgtk-3-dev libudev-dev squashfs-tools protobuf-compiler diff --git a/.github/workflows/ci-contracts-schema.yml b/.github/workflows/ci-contracts-schema.yml index 790d06d9f6..cb37e5d799 100644 --- a/.github/workflows/ci-contracts-schema.yml +++ b/.github/workflows/ci-contracts-schema.yml @@ -2,10 +2,6 @@ name: ci-contracts-schema on: workflow_dispatch: - push: - paths: - - 'contracts/**' - - 'common/**' pull_request: paths: - 'contracts/**' diff --git a/.github/workflows/ci-contracts-upload-binaries.yml b/.github/workflows/ci-contracts-upload-binaries.yml index 147ddf3ff3..c5466d7506 100644 --- a/.github/workflows/ci-contracts-upload-binaries.yml +++ b/.github/workflows/ci-contracts-upload-binaries.yml @@ -2,10 +2,6 @@ name: ci-contracts-upload-binaries on: workflow_dispatch: - push: - paths: - - 'common/**' - - 'contracts/**' pull_request: paths: - 'common/**' @@ -24,8 +20,6 @@ jobs: runs-on: ${{ matrix.platform }} env: CARGO_TERM_COLOR: always - # a push event from the origin repo, or a PR from external repo - if: ${{ github.event_name == 'push' || github.event.pull_request.head.repo.full_name != 'nymtech/nym' }} steps: - uses: actions/checkout@v3 @@ -38,10 +32,6 @@ jobs: mkdir -p $OUTPUT_DIR echo $OUTPUT_DIR - - name: Install Dependencies (Linux) - run: sudo apt-get update && sudo apt-get -y install libwebkit2gtk-4.0-dev build-essential curl wget libssl-dev libgtk-3-dev libudev-dev squashfs-tools protobuf-compiler - continue-on-error: true - - name: Install Rust stable uses: actions-rs/toolchain@v1 with: @@ -50,7 +40,9 @@ jobs: override: true - name: Install wasm-opt - run: cargo install --version 0.112.0 wasm-opt + uses: ./.github/actions/install-wasm-opt + with: + version: '112' - name: Build release contracts run: make contracts diff --git a/.github/workflows/ci-lint-typescript.yml b/.github/workflows/ci-lint-typescript.yml index bf9e4bf924..fec923c03d 100644 --- a/.github/workflows/ci-lint-typescript.yml +++ b/.github/workflows/ci-lint-typescript.yml @@ -1,15 +1,6 @@ name: ci-lint-typescript on: - push: - paths: - - "ts-packages/**" - - "sdk/typescript/**" - - "nym-connect/desktop/src/**" - - "nym-connect/desktop/package.json" - - "nym-wallet/src/**" - - "nym-wallet/package.json" - - "explorer/**" pull_request: paths: - "ts-packages/**" @@ -37,10 +28,14 @@ jobs: uses: actions-rs/toolchain@v1 with: toolchain: stable + - name: Install wasm-pack run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh + - name: Install wasm-opt - run: cargo install wasm-opt + uses: ./.github/actions/install-wasm-opt + with: + version: '116' - name: Set up Go uses: actions/setup-go@v4 diff --git a/.github/workflows/run-api-tests.yml b/.github/workflows/ci-nym-api-tests.yml similarity index 100% rename from .github/workflows/run-api-tests.yml rename to .github/workflows/ci-nym-api-tests.yml diff --git a/.github/workflows/ci-nym-connect-desktop-rust.yml b/.github/workflows/ci-nym-connect-desktop-rust.yml index 0eea154550..e5e56b8f43 100644 --- a/.github/workflows/ci-nym-connect-desktop-rust.yml +++ b/.github/workflows/ci-nym-connect-desktop-rust.yml @@ -1,16 +1,6 @@ name: ci-nym-connect-desktop-rust on: - push: - paths: - - "nym-connect/desktop/src-tauri/**" - - "nym-connect/desktop/src-tauri/Cargo.toml" - - "clients/client-core/**" - - "clients/socks5/**" - - "common/**" - - "gateway/gateway-requests/**" - - "contracts/vesting/**" - - "nym-api/nym-api-requests/**" pull_request: paths: - "nym-connect/desktop/src-tauri/**" @@ -27,8 +17,6 @@ jobs: runs-on: [self-hosted, custom-linux] env: CARGO_TERM_COLOR: always - # env: - # RUSTC_WRAPPER: /home/ubuntu/.cargo/bin/sccache steps: - name: Install Dependencies (Linux) run: sudo apt-get update && sudo apt-get -y install libwebkit2gtk-4.0-dev build-essential curl wget libssl-dev libgtk-3-dev squashfs-tools libayatana-appindicator3-dev diff --git a/.github/workflows/ci-nym-connect-desktop.yml b/.github/workflows/ci-nym-connect-desktop.yml index 5955de1ffa..5938e3a606 100644 --- a/.github/workflows/ci-nym-connect-desktop.yml +++ b/.github/workflows/ci-nym-connect-desktop.yml @@ -1,7 +1,7 @@ name: ci-nym-connect-desktop on: - push: + pull_request: paths: - 'nym-connect/desktop/**' diff --git a/.github/workflows/ci-nym-wallet-rust.yml b/.github/workflows/ci-nym-wallet-rust.yml index 8d95a534c4..8f865195e7 100644 --- a/.github/workflows/ci-nym-wallet-rust.yml +++ b/.github/workflows/ci-nym-wallet-rust.yml @@ -19,8 +19,6 @@ jobs: runs-on: [ self-hosted, custom-linux ] env: CARGO_TERM_COLOR: always - # env: - # RUSTC_WRAPPER: /home/ubuntu/.cargo/bin/sccache steps: - name: Install Dependencies (Linux) run: sudo apt-get update && sudo apt-get -y install libwebkit2gtk-4.0-dev build-essential curl wget libssl-dev libgtk-3-dev squashfs-tools diff --git a/.github/workflows/ci-nym-wallet-storybook.yml b/.github/workflows/ci-nym-wallet-storybook.yml index 7b17b2a741..9ba9cd3d9f 100644 --- a/.github/workflows/ci-nym-wallet-storybook.yml +++ b/.github/workflows/ci-nym-wallet-storybook.yml @@ -1,7 +1,7 @@ -name: Nym Wallet Storybook +name: ci-nym-wallet-storybook on: - push: + pull_request: paths: - 'nym-wallet/**' @@ -10,26 +10,35 @@ jobs: runs-on: custom-linux steps: - uses: actions/checkout@v2 + - name: Install rsync run: sudo apt-get install rsync continue-on-error: true + - uses: rlespinasse/github-slug-action@v3.x + - uses: actions/setup-node@v3 with: node-version: 18 + - name: Setup yarn run: npm install -g yarn + - name: Install Rust stable uses: actions-rs/toolchain@v1 with: toolchain: stable + - name: Install wasm-pack - run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh + run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh + - name: Build dependencies run: yarn && yarn build + - name: Build storybook run: yarn storybook:build working-directory: ./nym-wallet + - name: Deploy branch to CI www (storybook) continue-on-error: true uses: easingthemes/ssh-deploy@main @@ -41,9 +50,11 @@ jobs: REMOTE_USER: ${{ secrets.CI_WWW_REMOTE_USER }} TARGET: ${{ secrets.CI_WWW_REMOTE_TARGET }}/wallet-${{ env.GITHUB_REF_SLUG }} EXCLUDE: "/dist/, /node_modules/" + - name: Matrix - Node Install run: npm install working-directory: .github/workflows/support-files + - name: Matrix - Send Notification env: NYM_NOTIFICATION_KIND: nym-wallet diff --git a/.github/workflows/ci-sdk-docs-typescript.yml b/.github/workflows/ci-sdk-docs-typescript.yml index b98d160b47..926adf0804 100644 --- a/.github/workflows/ci-sdk-docs-typescript.yml +++ b/.github/workflows/ci-sdk-docs-typescript.yml @@ -1,10 +1,6 @@ name: ci-sdk-docs-typescript on: - push: - paths: - - "sdk/typescript/**" - - "wasm/**" pull_request: paths: - "sdk/typescript/**" @@ -34,6 +30,14 @@ jobs: with: go-version: '1.20' + - name: Install wasm-pack + run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh + + - name: Install wasm-opt + uses: ./.github/actions/install-wasm-opt + with: + version: '116' + - name: Build branch WASM packages run: make sdk-wasm-build diff --git a/.github/workflows/ci-sdk-wasm.yml b/.github/workflows/ci-sdk-wasm.yml index 4cd34ece69..074083042d 100644 --- a/.github/workflows/ci-sdk-wasm.yml +++ b/.github/workflows/ci-sdk-wasm.yml @@ -18,7 +18,7 @@ jobs: - uses: actions/setup-node@v3 with: node-version: 18 - + - uses: actions-rs/toolchain@v1 with: profile: minimal @@ -32,12 +32,13 @@ jobs: with: go-version: '1.20' - - name: Install wasm-pack run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh - name: Install wasm-opt - run: cargo install wasm-opt + uses: ./.github/actions/install-wasm-opt + with: + version: '116' - name: Install wasm-bindgen-cli run: cargo install wasm-bindgen-cli diff --git a/.github/workflows/greetings.yml b/.github/workflows/greetings.yml index 6afe9f37aa..6b31063c73 100644 --- a/.github/workflows/greetings.yml +++ b/.github/workflows/greetings.yml @@ -1,4 +1,4 @@ -name: Greetings +name: greetings on: [pull_request_target, issues] diff --git a/.github/workflows/nightly-security-audit.yml b/.github/workflows/nightly-security-audit.yml index a286050abb..808cc20144 100644 --- a/.github/workflows/nightly-security-audit.yml +++ b/.github/workflows/nightly-security-audit.yml @@ -1,4 +1,4 @@ -name: Daily security audit +name: nightly-security-audit on: schedule: diff --git a/.github/workflows/publish-nyms5-android-apk.yml b/.github/workflows/publish-nyms5-android-apk.yml index e143fef431..06f4c6c126 100644 --- a/.github/workflows/publish-nyms5-android-apk.yml +++ b/.github/workflows/publish-nyms5-android-apk.yml @@ -1,4 +1,4 @@ -name: Nyms5 Android +name: publish-nyms5-android-apk # unsigned APKs only, supported archs: # - arm64-v8a (arm64) # - x86_64