Skip to content

Commit 5ab3189

Browse files
authored
Merge pull request #2494 from flacial/feature/preview-deployment-workflow
ci(github-action): Add preview-db initializing workflow
2 parents 7789c0d + 8ba1019 commit 5ab3189

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: init-preview-db
2+
on:
3+
pull_request:
4+
types:
5+
- closed
6+
paths:
7+
- '**.prisma'
8+
jobs:
9+
ssh-and-update-preview-db:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: appleboy/ssh-action@master
13+
with:
14+
host: ${{ secrets.PREVIEW_DB_HOST }}
15+
username: ${{ secrets.PREVIEW_DB_USERNAME }}
16+
password: ${{ secrets.PREVIEW_DB_PW }}
17+
script: |
18+
cd c0d3-app
19+
git pull origin master
20+
yarn --ignore-engines
21+
yarn db:init --force

0 commit comments

Comments
 (0)