Betrieb: CI mit Multi-Arch-Image, Rollback, HTTPS-Profil, API-Doku

- GitHub Actions: Tests, danach Image für amd64/arm64 nach ghcr.io (latest + sha-Tags)
- docker-compose: fertiges Image mit Build-Fallback, Versions-Tag, Caddy-Profil „https“ (tls internal)
- deploy-pi.sh holt das Image (Fallback: lokal bauen) und prüft die Gesundheit; rollback.sh für Version oder Datenbanksicherung
- Dockerfile mit Versionslabel, ohne Testdateien
- docs/API.md: vollständige REST/WebSocket-Schnittstelle; KONZEPT: Architektur, Sicherheit, Roadmap aktualisiert

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018i4GUhQVoPUusUzxgxLWkK
This commit is contained in:
db9979andClaude Opus 5.5 committed 2026-12-03 14:00:36 +00:00
1 parent ec6b3642a6
commit e93135cc83
9 files changed
+347 -42

No files matched your search

+64
View File
@@ -0,0 +1,64 @@
name: CI
on:
push:
branches: [main]
tags: ['v*']
pull_request:
workflow_dispatch:
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: server
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
cache-dependency-path: server/package-lock.json
- run: npm ci
- run: npm test
image:
# Multi-Arch-Image (amd64 + arm64 für den Raspberry Pi) nach ghcr.io – nur nach erfolgreichen Tests auf main/Tags
needs: test
if: github.event_name != 'pull_request'
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
- uses: docker/setup-qemu-action@v3
- uses: docker/setup-buildx-action@v3
- uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- id: meta
uses: docker/metadata-action@v5
with:
images: ghcr.io/${{ github.repository }}
tags: |
type=raw,value=latest,enable={{is_default_branch}}
type=sha,format=short
type=semver,pattern={{version}}
- uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
build-args: VERSION=${{ github.sha }}
cache-from: type=gha
cache-to: type=gha,mode=max