- Root monorepo: /backend (Go) + /frontend (Next.js 15) - Go module: mgit.msbls.de/m/KanzlAI with minimal HTTP server - Next.js 15: TypeScript strict, Tailwind CSS v4, App Router, Bun - Root Makefile: dev, build, lint, test targets - Root .gitignore covering Go, Node, IDE, OS files - CLAUDE.md updated with project structure and tech stack - .claude/CLAUDE.md with coding conventions (Go stdlib style, TS strict)
26 lines
408 B
Go
26 lines
408 B
Go
package main
|
|
|
|
import (
|
|
"fmt"
|
|
"log"
|
|
"net/http"
|
|
"os"
|
|
)
|
|
|
|
func main() {
|
|
port := os.Getenv("PORT")
|
|
if port == "" {
|
|
port = "8080"
|
|
}
|
|
|
|
http.HandleFunc("/health", func(w http.ResponseWriter, r *http.Request) {
|
|
w.WriteHeader(http.StatusOK)
|
|
fmt.Fprintf(w, "ok")
|
|
})
|
|
|
|
log.Printf("Starting KanzlAI API server on :%s", port)
|
|
if err := http.ListenAndServe(":"+port, nil); err != nil {
|
|
log.Fatal(err)
|
|
}
|
|
}
|