Skip to content

Commit

Permalink
Merge pull request #6 from chat-apropo/caprover-ci
Browse files Browse the repository at this point in the history
Add caprover CD
  • Loading branch information
matheusfillipe authored Feb 17, 2024
2 parents 93be5cb + 7f2f8e5 commit fe3c63c
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 2 deletions.
28 changes: 26 additions & 2 deletions .github/workflows/workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,9 @@ jobs:
run: ruff --output-format=github .
continue-on-error: true

deploy:
name: Deploy app
deploy-fly:
name: Deploy prod app to https://g4f-api.fly.dev/
# Only from main branch
if: github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
steps:
Expand All @@ -41,3 +42,26 @@ jobs:
- run: flyctl deploy --remote-only
env:
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}


deploy-caprover:
# Always deploy
name: Deploy dev app to https://g4f-api.cloud.mattf.one/
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
path: g4f-api
- uses: a7ul/tar-action@v1.1.0
with:
command: c
cwd: "./"
files: "g4f-api/"
outPath: deploy.tar

- name: Deploy App to CapRover
uses: caprover/deploy-from-github@v1.0.1
with:
server: '${{ secrets.CAPROVER_SERVER }}'
app: '${{ secrets.APP_NAME }}'
token: '${{ secrets.APP_TOKEN }}'
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ Alternative Api for getting text complections from the [g4f project](https://git
### Live at
- https://g4f-api-ko37.onrender.com
- https://g4f-api.fly.dev/
- https://g4f-api.cloud.mattf.one/

0 comments on commit fe3c63c

Please sign in to comment.