Files
t 2bbf42b741 refactor(auth): delegate access control to be-system
Remove Agent Desk users, roles, login sessions, tokens, and local permission persistence. Expose the backend as an embeddable ai-agent module with host-provided subject lookup and operation authorization callbacks, and complete the frontend/backend repository split.
2026-08-21 00:41:07 +08:00

33 lines
645 B
Go

package main
import (
"flag"
"log/slog"
"code.tczkiot.com/wlw/ai-agent/internal/bootstrap"
"code.tczkiot.com/wlw/ai-agent/internal/pkg/config"
)
func main() {
configPath := flag.String("config", "config/config.yaml", "path to config file")
flag.Parse()
if err := bootstrap.Init(*configPath); err != nil {
slog.Error("bootstrap init failed", "error", err)
return
}
cfg := config.Current()
app, err := bootstrap.NewServer()
if err != nil {
slog.Error("bootstrap server failed", "error", err)
return
}
if err := app.Run(cfg.Server.Address()); err != nil {
slog.Error("start server failed", "error", err)
return
}
}