Skip to content

Commit

Permalink
ci: avoiding having to build tarball
Browse files Browse the repository at this point in the history
This also makes so we see the git commit hash in caprover's UI
  • Loading branch information
matheusfillipe committed Feb 17, 2024
1 parent c5cb0cb commit d46b90a
Showing 1 changed file with 13 additions and 12 deletions.
25 changes: 13 additions & 12 deletions .github/workflows/workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,19 +49,20 @@ jobs:
name: Deploy dev app to https://g4f-api.cloud.mattf.one/
runs-on: ubuntu-latest
steps:
- name: Install git to ensure deployment hash
run: sudo apt update; sudo apt-get install -y git

- 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
fetch-depth: 0

- run: git archive --format tar --output "./deploy.tar" query-params-config
- run: git rev-parse query-params-config
- 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 }}'
run: |
npm install -g caprover
caprover deploy \
--caproverUrl '${{ secrets.CAPROVER_SERVER }}' \
--appToken '${{ secrets.APP_TOKEN }}' \
--appName '${{ secrets.APP_NAME }}' \
-b '${{ github.head_ref || github.ref_name }} '

0 comments on commit d46b90a

Please sign in to comment.