feat: Enhance import handler to support mounted Caddyfile and improve conflict reporting

This commit is contained in:
Wikid82
2025-11-24 17:32:56 +00:00
parent fce717f7d9
commit 8babd2f430
7 changed files with 198 additions and 87 deletions

View File

@@ -100,7 +100,7 @@ func main() {
}
// Register import handler with config dependencies
routes.RegisterImportHandler(router, db, cfg.CaddyBinary, cfg.ImportDir)
routes.RegisterImportHandler(router, db, cfg.CaddyBinary, cfg.ImportDir, cfg.ImportCaddyfile)
// Check for mounted Caddyfile on startup
if err := handlers.CheckMountedImport(db, cfg.ImportCaddyfile, cfg.CaddyBinary, cfg.ImportDir); err != nil {