Files
md-blog/.github/workflows/deploy.yml
T
klemek 85783efb81
Deploy / build (push) Failing after 3m22s
Deploy / deploy (push) Has been cancelled
ci: update deploy ci for gitea
2026-05-01 22:56:23 +02:00

42 lines
954 B
YAML

name: Deploy
concurrency:
group: deploy-${{ github.ref }}
cancel-in-progress: true
on:
push:
branches:
- 'main'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: https://github.com/oven-sh/setup-bun@v2
with:
bun-version: latest
- uses: actions/checkout@v6
- run: bun ci
- run: bun run build
- uses: actions/upload-artifact@v3
with:
name: production-files
path: dist/
deploy:
runs-on: ubuntu-latest
needs: build
if: ${{ vars.STAPLER_TARGET != '' }}
steps:
- uses: actions/download-artifact@v3
with:
name: production-files
path: ./dist
- run: tar -czC dist -f dist.tar.gz .
- run: |
curl -s -X PUT --data-binary "@dist.tar.gz" \
-H 'X-Token: ${{ secrets.STAPLER_TOKEN }}' \
${{ vars.STAPLER_CURL_ARGS }} \
${{ vars.STAPLER_TARGET }}