Skip to content

Commit

Permalink
Require secrets to be set to run Pages deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
sealer3 committed Apr 25, 2024
1 parent 9494667 commit 008389f
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
14 changes: 14 additions & 0 deletions .github/workflows/integration-deployment.yaml
Original file line number Diff line number Diff line change
@@ -1,28 +1,42 @@
on: [push]
jobs:
check-secrets:
if: github.repository == 'otterscan/otterscan'
runs-on: ubuntu-latest
steps:
- name: Check if repository name supports this workflow
- run: echo
deploy-mainnet:
uses: ./.github/workflows/pages-deployment.yaml
if: github.repository == 'otterscan/otterscan'
needs: [check-secrets]
secrets:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{ secrets.CLOUDFLARE_INTEG_MAINNET_PROJECT }}
viteConfigJson: ${{ secrets.CLOUDFLARE_INTEG_MAINNET_SETTINGS }}
deploy-gnosis:
uses: ./.github/workflows/pages-deployment.yaml
if: github.repository == 'otterscan/otterscan'
needs: [check-secrets]
secrets:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{ secrets.CLOUDFLARE_INTEG_GNOSIS_PROJECT }}
viteConfigJson: ${{ secrets.CLOUDFLARE_INTEG_GNOSIS_SETTINGS }}
deploy-op-mainnet:
uses: ./.github/workflows/pages-deployment.yaml
if: github.repository == 'otterscan/otterscan'
needs: [check-secrets]
secrets:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{ secrets.CLOUDFLARE_INTEG_OP_MAINNET_PROJECT }}
viteConfigJson: ${{ secrets.CLOUDFLARE_INTEG_OP_MAINNET_SETTINGS }}
deploy-e3-sepolia:
uses: ./.github/workflows/pages-deployment.yaml
if: github.repository == 'otterscan/otterscan'
needs: [check-secrets]
secrets:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pages-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ jobs:
permissions:
contents: read
deployments: write
if: github.repository == 'otterscan/otterscan'
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down

0 comments on commit 008389f

Please sign in to comment.