ci: add deploy workflow for custom branch (OpenChamber-CUSTOM)

This commit is contained in:
2026-09-03 11:36:34 +00:00
parent 057e451068
commit e67987533e
+25
View File
@@ -0,0 +1,25 @@
name: deploy-custom
on:
push:
branches: [custom]
jobs:
deploy:
runs-on: linux-amd64
steps:
- name: Show revision
run: git -C $GITHUB_WORKSPACE rev-parse --short HEAD
- name: Copy workspace to build dir
run: |
rm -rf /opt/app/deploy/custom-build
mkdir -p /opt/app/deploy/custom-build
tar -C $GITHUB_WORKSPACE --exclude=.git -cf - . | tar -C /opt/app/deploy/custom-build -xf -
- name: Install dependencies
run: cd /opt/app/deploy/custom-build && bun install --frozen-lockfile
- name: Build web
run: cd /opt/app/deploy/custom-build && bun run build:web
- name: Verify dist
run: test -f /opt/app/deploy/custom-build/packages/web/dist/index.html
- name: Swap current symlink
run: ln -sfn /opt/app/deploy/custom-build /opt/app/deploy/current
- name: Restart service
run: sudo systemctl restart openchamber-custom