aboutsummaryrefslogtreecommitdiff
path: root/internal/router
diff options
context:
space:
mode:
Diffstat (limited to 'internal/router')
-rw-r--r--internal/router/router.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/internal/router/router.go b/internal/router/router.go
index abe4f8b..d729d16 100644
--- a/internal/router/router.go
+++ b/internal/router/router.go
@@ -48,8 +48,10 @@ func ShoelacesRouter(env *environment.Environment) http.Handler {
// Static configuration files endpoint
r.PathPrefix("/configs/static/").Handler(http.StripPrefix("/configs/static/",
handlers.StaticConfigFileServer()))
+
// Dynamic configuration endpoint
- r.HandleFunc("/configs/{key}", handlers.TemplateHandler).Methods("GET")
+ r.PathPrefix("/configs/").Handler(http.StripPrefix("/configs/",
+ handlers.TemplateServer()))
// Called by iPXE boot agents, returns boot script specified on the configuration
// or if the host is unknown makes it retry for a while until the user specifies
nihil fit ex nihilo