From 55f56418df58d196daa97f3c08e3b6305e831b82 Mon Sep 17 00:00:00 2001 From: Niall Sheridan Date: Fri, 5 Aug 2016 06:35:19 +0100 Subject: Use bootstrap Move templates and static under server/ --- cmd/cashierd/main.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'cmd') diff --git a/cmd/cashierd/main.go b/cmd/cashierd/main.go index 67af7cf..b530af9 100644 --- a/cmd/cashierd/main.go +++ b/cmd/cashierd/main.go @@ -29,8 +29,9 @@ import ( "github.com/nsheridan/cashier/server/config" "github.com/nsheridan/cashier/server/fs" "github.com/nsheridan/cashier/server/signer" + "github.com/nsheridan/cashier/server/static" "github.com/nsheridan/cashier/server/store" - "github.com/nsheridan/cashier/templates" + "github.com/nsheridan/cashier/server/templates" ) var ( @@ -359,6 +360,7 @@ func main() { r.Methods("GET").Path("/revoked").Handler(appHandler{ctx, listRevokedCertsHandler}) r.Methods("POST").Path("/admin/revoke").Handler(CSRF(appHandler{ctx, revokeCertHandler})) r.Methods("GET").Path("/admin/certs").Handler(CSRF(appHandler{ctx, listAllCertsHandler})) + r.PathPrefix("/").Handler(http.FileServer(static.FS(true))) logfile := os.Stderr if config.Server.HTTPLogFile != "" { logfile, err = os.OpenFile(config.Server.HTTPLogFile, os.O_WRONLY|os.O_APPEND|os.O_CREATE, 0660) -- cgit v1.2.3