From 4cf5ea0f8f1b14d6d381abe704f0113c1dbe77be Mon Sep 17 00:00:00 2001 From: kent-3 <100624004+kent-3@users.noreply.github.com> Date: Fri, 2 Aug 2024 21:26:59 -0400 Subject: [PATCH] change all workflows to manual dispatch --- .github/workflows/Deploy.yml | 14 +++++++------- .github/workflows/Foundry_tests.yml | 9 +++++---- .github/workflows/Python_tests.yml | 12 +++++------- .github/workflows/Secret_credit_score_tests.yml | 7 ++++--- .github/workflows/Secret_gateway_tests.yml | 7 ++++--- .github/workflows/Webserver_only_deploy.yml | 8 ++++---- 6 files changed, 29 insertions(+), 28 deletions(-) diff --git a/.github/workflows/Deploy.yml b/.github/workflows/Deploy.yml index 097d405..4771816 100644 --- a/.github/workflows/Deploy.yml +++ b/.github/workflows/Deploy.yml @@ -1,15 +1,15 @@ name: Deployment on: - push: - branches: - - main - paths-ignore: - - 'README.md' + workflow_dispatch: + # push: + # branches: + # - main + # paths-ignore: + # - 'README.md' jobs: Deploy-to-main: - runs-on: ubuntu-latest steps: @@ -91,7 +91,7 @@ jobs: ETH_PRIVATE_KEY: ${{secrets.ETH_PRIVATE_KEY}} ETHERSCAN_KEY: ${{secrets.ETHERSCAN_KEY}} SECRET_GATEWAY_ETH_ADDRESS: ${{env.SECRET_GATEWAY_ETH_ADDRESS}} - run: | + run: | forge script script/DeployScript.s.sol:DeployScript --rpc-url "$INFURA_API_URL" --private-key "$ETH_PRIVATE_KEY" --etherscan-api-key "$ETHERSCAN_KEY" --broadcast --verify --retries 10 -vvvv echo "ETH_GATEWAY_ADDRESS=$(jq -r '.transactions[1].contractAddress' /home/runner/work/TNLS/TNLS/public-gateway/broadcast/DeployScript.s.sol/5/run-latest.json)" >> $GITHUB_ENV echo "ETH_CLIENT_ADDRESS=$(jq -r '.transactions[2].contractAddress' /home/runner/work/TNLS/TNLS/public-gateway/broadcast/DeployScript.s.sol/5/run-latest.json)" >> $GITHUB_ENV diff --git a/.github/workflows/Foundry_tests.yml b/.github/workflows/Foundry_tests.yml index da32c63..3801f0d 100644 --- a/.github/workflows/Foundry_tests.yml +++ b/.github/workflows/Foundry_tests.yml @@ -1,8 +1,9 @@ name: Foundry Tests on: - push: - paths: - - 'public-gateway/**' + workflow_dispatch: + # push: + # paths: + # - 'public-gateway/**' jobs: tests: @@ -27,4 +28,4 @@ jobs: run: forge test -vvv - name: Check gas snapshots - run: forge snapshot --check \ No newline at end of file + run: forge snapshot --check diff --git a/.github/workflows/Python_tests.yml b/.github/workflows/Python_tests.yml index ae67376..d0902ed 100644 --- a/.github/workflows/Python_tests.yml +++ b/.github/workflows/Python_tests.yml @@ -1,15 +1,14 @@ name: Python package on: - push: - paths: - - 'TNLS-Relayers/**' - - '.github/workflows/Python_tests.yml' - + workflow_dispatch: + # push: + # paths: + # - 'TNLS-Relayers/**' + # - '.github/workflows/Python_tests.yml' jobs: build-and-test-python: - runs-on: ubuntu-latest steps: @@ -54,7 +53,6 @@ jobs: chmod +x ./upload_scrt_contract.sh SGX_MODE=SW ./upload_scrt_contract.sh - - name: Test with pytest working-directory: ./TNLS-Relayers run: | diff --git a/.github/workflows/Secret_credit_score_tests.yml b/.github/workflows/Secret_credit_score_tests.yml index bf06d4f..8ec20db 100644 --- a/.github/workflows/Secret_credit_score_tests.yml +++ b/.github/workflows/Secret_credit_score_tests.yml @@ -1,9 +1,10 @@ name: Secret Credit Score on: - push: - paths: - - 'TNLS-Samples/credit-score/**' + workflow_dispatch: + # push: + # paths: + # - 'TNLS-Samples/credit-score/**' jobs: credit_score_tests: diff --git a/.github/workflows/Secret_gateway_tests.yml b/.github/workflows/Secret_gateway_tests.yml index e621292..94b25ca 100644 --- a/.github/workflows/Secret_gateway_tests.yml +++ b/.github/workflows/Secret_gateway_tests.yml @@ -1,9 +1,10 @@ name: Secret Gateway on: - push: - paths: - - 'TNLS-Gateways/secret/**' + workflow_dispatch: + # push: + # paths: + # - 'TNLS-Gateways/secret/**' jobs: secret_gateway_tests: diff --git a/.github/workflows/Webserver_only_deploy.yml b/.github/workflows/Webserver_only_deploy.yml index 9593067..5bc3fd9 100644 --- a/.github/workflows/Webserver_only_deploy.yml +++ b/.github/workflows/Webserver_only_deploy.yml @@ -1,13 +1,13 @@ name: Deployment-Webserver on: - push: - branches: - - nonexistent-branch + workflow_dispatch: + # push: + # branches: + # - nonexistent-branch jobs: Deploy-webserver-to-main: - runs-on: ubuntu-latest steps: