Backend (src/server, runs on Bun): - GibbzHttpServer (health, /api/ice, /api/rooms, static, keepalive tuning) - SignalingServer with Peer/Room/RoomRegistry classes and typed messages - IceConfigProvider (env STUN/TURN + coturn HMAC ephemeral creds) - StaticFileServer (dist/ with public/ fallback, traversal guard) - Tracing (OpenTelemetry SDK), AppConfig; createApp() factory for tests Frontend (src/client, built by Vite): - VoiceApp orchestrator implementing VoiceAppContext - WebRtcManager + PeerSession (perfect negotiation, pc rebuild, quality monitor) - SignalingClient + ReconnectController, AudioManager, SpatialAudio, Microphone/ScreenShare controllers, ScreensUi/RosterUi/SpatialMap/ SpeakingMonitor, Settings/Welcome dialogs, LayoutManager, MatrixChat Tooling: bun scripts (dev/start/test/typecheck), vite.config.ts root src/client with publicDir public/static, vitest-config for CI-less runs, bun-based Dockerfile (oven/bun:1), Makefile + README updated, legacy server.js/tracing.js/test.js/public js removed. Verified locally: tsc --noEmit clean, vitest run 6/6 green, vite build ok, server smoke-tested serving dist + signaling endpoints under Node. Local bun binary segfaults (SIGILL) on this host, so 'bun test' itself was not executable here; tests are vitest-API compatible which bun test maps.
48 lines
1.4 KiB
Makefile
48 lines
1.4 KiB
Makefile
IMAGE ?= matst80/gibbz:latest
|
|
NAMESPACE ?= home
|
|
VERSION ?= $(shell git describe --tags --exact-match 2>/dev/null || git rev-parse --short=12 HEAD)
|
|
GIT_COMMIT ?= $(shell git rev-parse HEAD)
|
|
BUILD_DATE ?= $(shell date -u +"%Y-%m-%dT%H:%M:%SZ")
|
|
|
|
.PHONY: all help build test check docker-build docker-push deploy rollout status logs
|
|
|
|
all: check
|
|
|
|
help: ## Show target help
|
|
@grep -E '^[a-zA-Z_-]+:.*?## ' $(MAKEFILE_LIST) | awk 'BEGIN{FS=":.*?## "}{printf " \033[36m%-16s\033[0m %s\n", $$1, $$2}'
|
|
|
|
test: ## Run tests (bun test)
|
|
bun test
|
|
|
|
check: test ## Quality gate: tests + typecheck
|
|
bun run typecheck
|
|
|
|
build: check ## Install deps and build the client bundle
|
|
bun install
|
|
bun run build
|
|
|
|
docker-build: ## Build docker image
|
|
docker build \
|
|
--build-arg APP_RELEASE=$(VERSION) \
|
|
--build-arg VERSION=$(VERSION) \
|
|
--build-arg GIT_COMMIT=$(GIT_COMMIT) \
|
|
--build-arg BUILD_DATE=$(BUILD_DATE) \
|
|
-t $(IMAGE) \
|
|
.
|
|
|
|
docker-push: ## Push docker image
|
|
docker push $(IMAGE)
|
|
|
|
deploy: ## Apply Kubernetes manifests to the cluster
|
|
kubectl apply -f k8s/deployment.yaml
|
|
|
|
rollout: ## Trigger rolling restart of the deployment
|
|
kubectl rollout restart deployment/gibbz -n $(NAMESPACE)
|
|
kubectl rollout status deployment/gibbz -n $(NAMESPACE)
|
|
|
|
status: ## Check deployment and pod status
|
|
kubectl get pods,svc,ingress -l app=gibbz -n $(NAMESPACE)
|
|
|
|
logs: ## Tail pod logs
|
|
kubectl logs -l app=gibbz -n $(NAMESPACE) -f
|