The HTTP server serves /healthz, the API namespace and the PWA, with the frontend embedded behind a build tag so a clean checkout compiles without a Node toolchain. /healthz reads the database rather than just answering: a process that cannot reach its own data is not healthy, and a 200 there would keep a broken container in rotation. The image is distroless and static — the SQLite driver is pure Go, so CGO stays off. The Rune manifest uses keep_entrypoint because there is no shell in the image to run a startup command with, and its log watchers match the JSON log format the container actually emits. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
16 lines
406 B
Go
16 lines
406 B
Go
//go:build !embedweb
|
|
|
|
package main
|
|
|
|
import (
|
|
"errors"
|
|
"io/fs"
|
|
)
|
|
|
|
// Without the embedweb tag there is no frontend in the binary. This is the normal
|
|
// state during backend development and on a clean checkout with no Node installed:
|
|
// the API runs, and anything that is not an API route says so in plain text.
|
|
func embeddedWeb() (fs.FS, error) {
|
|
return nil, errors.New("built without -tags embedweb")
|
|
}
|