- Single fixed 'Haven' board: lists (To do/In progress/Done) + cards, no multi-board - Go 1.24 backend, CGO-free modernc.org/sqlite, embedded SPA, REST /api - Preact + Vite + TS frontend, native HTML5 drag-and-drop, optimistic UI, dark Haven theme - PVC (nfs-client) for SQLite, root container on NFS, simple nginx ingress havenllo.haven - Dockerfile multi-arch build, Gitea CI via pipeline-actions@main
60 lines
1.8 KiB
YAML
60 lines
1.8 KiB
YAML
name: Build and deploy Havenllo
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
verify:
|
|
name: Verify Go and frontend
|
|
runs-on: runner-slim-amd64
|
|
steps:
|
|
- name: Check out source
|
|
uses: actions/checkout@v4
|
|
- name: Test Go
|
|
run: go test ./...
|
|
- name: Install frontend dependencies
|
|
working-directory: web
|
|
run: npm ci
|
|
- name: Build frontend
|
|
working-directory: web
|
|
run: npm run build
|
|
- name: Validate Kubernetes manifest
|
|
run: |
|
|
if command -v kubectl >/dev/null 2>&1; then
|
|
kubectl apply --dry-run=client -f deploy/havenllo.yaml
|
|
fi
|
|
build:
|
|
name: Build and push image
|
|
needs: verify
|
|
runs-on: runner-slim-amd64
|
|
steps:
|
|
- name: Check out source
|
|
uses: actions/checkout@v4
|
|
- name: Build and push multi-architecture image
|
|
uses: https://git.ivanch.me/ivanch/pipeline-actions/build-and-push@main
|
|
with:
|
|
image: git.ivanch.me/ivanch/havenllo
|
|
image_tag: latest
|
|
registry_password: ${{ secrets.REGISTRY_PASSWORD }}
|
|
ssh_key: ${{ secrets.SSH_KEY_DOCKERBUILD }}
|
|
deploy:
|
|
name: Apply and restart Havenllo
|
|
needs: build
|
|
runs-on: runner-slim-amd64
|
|
steps:
|
|
- name: Check out source
|
|
uses: actions/checkout@v4
|
|
- name: Apply Kubernetes manifest
|
|
uses: https://git.ivanch.me/ivanch/pipeline-actions/kubectl-apply@main
|
|
with:
|
|
manifest: deploy/havenllo.yaml
|
|
kube_config: ${{ secrets.KUBE_CONFIG }}
|
|
- name: Restart deployment
|
|
uses: https://git.ivanch.me/ivanch/pipeline-actions/deploy-restart@main
|
|
with:
|
|
deployment_name: havenllo
|
|
namespace: default
|
|
kube_config: ${{ secrets.KUBE_CONFIG }}
|