sigit.io/.gitea/workflows/release-staging.yaml
daniyal 73a5d42fcf
All checks were successful
Open PR on Staging / audit_and_check (pull_request) Successful in 41s
chore(workflow-audit): omit dev dependencies in npm audit
2024-08-22 14:37:23 +05:00

47 lines
1.0 KiB
YAML

name: Release to Staging
on:
push:
branches:
- staging
jobs:
build_and_release:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v2
with:
node-version: 18
- name: Audit
run: npm audit --omit=dev
- name: Install Dependencies
run: npm ci
- name: License check
run: npm run license-checker
- name: Lint check
run: npm run lint
- name: Formatter check
run: npm run formatter:check
- name: Create .env File
run: echo "VITE_MOST_POPULAR_RELAYS=${{ vars.VITE_MOST_POPULAR_RELAYS }}" > .env
- name: Create Build
run: npm run build
- name: Release Build
run: |
npm -g install cloudron-surfer
surfer config --token ${{ secrets.STAGING_CLOUDRON_SURFER_TOKEN }} --server staging.sigit.io
surfer put dist/* / --all -d
surfer put dist/.well-known / --all