feat: Archivum skeleton — Go/GraphQL backend + Vue 3 PWA frontend
Full project scaffold: multi-stage Dockerfile (ARM64/AMD64), AsciiDoc↔TipTap bridge, Setup Wizard, CodeMirror source editor, Git-backed storage layer, LDAP+JWT auth skeleton, Tailwind mobile-first layout, and VS Code build/push tasks targeting registry at 192.168.0.19:5000. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
31
backend/cmd/server/main.go
Normal file
31
backend/cmd/server/main.go
Normal file
@@ -0,0 +1,31 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"log"
|
||||
"net/http"
|
||||
"os"
|
||||
|
||||
"github.com/brasse-b/archivum/internal/config"
|
||||
"github.com/brasse-b/archivum/internal/graph"
|
||||
)
|
||||
|
||||
func main() {
|
||||
cfg, err := config.Load(configPath())
|
||||
if err != nil {
|
||||
log.Fatalf("failed to load config: %v", err)
|
||||
}
|
||||
|
||||
srv := graph.NewServer(cfg)
|
||||
|
||||
log.Printf("Archivum listening on %s", cfg.ListenAddr)
|
||||
if err := http.ListenAndServe(cfg.ListenAddr, srv); err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
func configPath() string {
|
||||
if p := os.Getenv("DOCKER_PATH"); p != "" {
|
||||
return p + "/config/config.json"
|
||||
}
|
||||
return "config.json"
|
||||
}
|
||||
Reference in New Issue
Block a user