Skip to content

Commit 6a8a333

Browse files
Merge pull request #92 from podcodar/nicolasbrandao/migrate-db-to-prod
Create Migrate Production DB Job
2 parents 7587d39 + 3cc9876 commit 6a8a333

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

.github/workflows/ci-migrate.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Migrate Production
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
migrate_production:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout Repository
13+
uses: actions/checkout@v3
14+
15+
- name: Build node env
16+
uses: actions/setup-node@v3
17+
with:
18+
node-version: 18
19+
20+
- name: Install Dependencies
21+
run: npm install
22+
23+
- name: Generate and Migrate
24+
run: npm run db:generate && npm run db:migrate deploy
25+
env:
26+
POSTGRES_URL: ${{ secrets.POSTGRES_URL }}

0 commit comments

Comments
 (0)