Skip to content

Commit

Permalink
dry run
Browse files Browse the repository at this point in the history
  • Loading branch information
LesnyRumcajs committed Nov 3, 2023
1 parent c272afc commit 7807d0e
Show file tree
Hide file tree
Showing 2 changed files with 56 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/deploy-cf-latest-snapshot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Deploy CF latest-snapshot
on:
pull_request:
paths:
- 'cf/latest-snapshot'
- '.github/workflows/deploy-cf-latest-snapshot.yml'
push:
paths:
- 'cf/latest-snapshot'
- '.github/workflows/deploy-cf-latest-snapshot.yml'

jobs:
check-and-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Deployment check
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
workingDirectory: "cf/latest-snapshot"
command: deploy --dry-run
- name: Deploy
if: github.ref == 'refs/heads/main' && ( github.event_name == 'push' || github.event_name == 'workflow_dispatch' )
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
workingDirectory: "cf/latest-snapshot"
28 changes: 28 additions & 0 deletions .github/workflows/deploy-cf-prune-latest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Deploy CF prune-latest
on:
pull_request:
paths:
- 'cf/prune-latest'
- '.github/workflows/deploy-cf-prune-latest.yml'
push:
paths:
- 'cf/prune-latest'
- '.github/workflows/deploy-cf-prune-latest.yml'

jobs:
check-and-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Deployment check
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
workingDirectory: "cf/prune-latest"
command: deploy --dry-run
- name: Deploy
if: github.ref == 'refs/heads/main' && ( github.event_name == 'push' || github.event_name == 'workflow_dispatch' )
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
workingDirectory: "cf/prune-latest"

0 comments on commit 7807d0e

Please sign in to comment.