Skip to content

Commit

Permalink
deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
kentcdodds committed Feb 20, 2024
1 parent 3835d63 commit e70def1
Showing 1 changed file with 31 additions and 5 deletions.
36 changes: 31 additions & 5 deletions .github/workflows/validate.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
name: validate
name: deploy

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

on:
push:
branches:
- 'main'
- 'next2'
pull_request:
branches:
- 'main'
- 'next2'
jobs:
setup:
# ignore all-contributors PRs
if: ${{ !contains(github.head_ref, 'all-contributors') }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
Expand All @@ -27,3 +28,28 @@ jobs:

- name: ▶️ Run setup script
run: npm run setup

- name: ʦ TypeScript
run: npm run typecheck

- name: ⬣ ESLint
run: npm run lint

deploy:
name: 🚀 Deploy
runs-on: ubuntu-latest
# only deploy main branch on pushes
if: ${{ github.ref == 'refs/heads/main' && github.event_name == 'push' }}

steps:
- name: ⬇️ Checkout repo
uses: actions/checkout@v3

- name: 🎈 Setup Fly
uses: superfly/flyctl-actions/[email protected]

- name: 🚀 Deploy
run: flyctl deploy --remote-only
working-directory: ./scripts/deployed
env:
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}

0 comments on commit e70def1

Please sign in to comment.