Skip to content

Merge pull request #3 from interscript/feat/code-only-worker-maps-art… #17

Merge pull request #3 from interscript/feat/code-only-worker-maps-art…

Merge pull request #3 from interscript/feat/code-only-worker-maps-art… #17

Workflow file for this run

name: deploy
on:
push:
branches: [main]
tags: ["v*"]
jobs:
deploy-staging:
if: github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with: { node-version: "22" }
- run: npm install
# Staging only: the workers.dev preview URL, never the production
# route. Production flips exclusively via a v* tag.
- run: npm run deploy:staging
env:
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
deploy-production:
if: startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
environment: production
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with: { node-version: "22" }
- run: npm install
- run: npm run deploy
env:
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}