ci: run deploy on self-hosted runner
This commit is contained in:
parent
882d1fc5a5
commit
3eab4984eb
13
.github/workflows/main.yml
vendored
13
.github/workflows/main.yml
vendored
|
|
@ -8,17 +8,18 @@ on:
|
|||
jobs:
|
||||
deploy:
|
||||
name: 🚀 Deploy
|
||||
runs-on: ubuntu-latest
|
||||
runs-on: self-hosted
|
||||
# only build/deploy main branch on pushes
|
||||
if: ${{ github.ref == 'refs/heads/main' && github.event_name == 'push' }}
|
||||
|
||||
steps:
|
||||
- name: ⬇️ Checkout repo
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
path: ../../explit
|
||||
|
||||
- name: ⚒ Build
|
||||
run: yarn build
|
||||
|
||||
- name: 🚀 Deploy
|
||||
uses: superfly/flyctl-actions@1.1
|
||||
with:
|
||||
args: "deploy --remote-only"
|
||||
env:
|
||||
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}
|
||||
run: pm2 startOrRestart ecosystem.config.js
|
||||
|
|
|
|||
Loading…
Reference in a new issue