Files
openchamber/.gitea/workflows/deploy-custom.yml
T
bot-hermes b3c24935c0 ci(deploy): use SSH URL for checkout clone
The https://gitea@giteassh.buzzbee.dev:Vibing/... URL parsed the colon as a
port. Use the SSH form gitea@giteassh.buzzbee.dev:Vibing/openchamber.git
which the runner's deploy key authenticates.
2026-09-05 09:00:04 -04:00

31 lines
1.2 KiB
YAML

name: deploy-custom
on:
push:
branches: [custom]
jobs:
deploy:
runs-on: linux-amd64
steps:
- name: Checkout
run: |
rm -rf $GITHUB_WORKSPACE/repo
mkdir -p $GITHUB_WORKSPACE/repo
git clone --depth 1 --branch custom gitea@giteassh.buzzbee.dev:Vibing/openchamber.git $GITHUB_WORKSPACE/repo
- name: Show revision
run: git -C $GITHUB_WORKSPACE/repo 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/repo --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