summaryrefslogtreecommitdiff
path: root/server/cmd
diff options
context:
space:
mode:
Diffstat (limited to 'server/cmd')
-rw-r--r--server/cmd/main.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/server/cmd/main.go b/server/cmd/main.go
index 72d2aad..75caf19 100644
--- a/server/cmd/main.go
+++ b/server/cmd/main.go
@@ -12,12 +12,13 @@ import (
"git.huntm.net/wedding/server/admin"
"git.huntm.net/wedding/server/guest"
+ "git.huntm.net/wedding/server/middleware"
)
var (
user = "postgres"
password = os.Getenv("PASS")
- host = "localhost"
+ host = "host.containers.internal"
port = "5432"
database = "wedding"
)
@@ -38,7 +39,7 @@ func main() {
mux := http.NewServeMux()
mux.Handle("/api/guests/", guestHandler)
mux.Handle("/api/admin/", adminHandler)
- log.Fatal(http.ListenAndServe(":8080", serveHTTP(mux)))
+ log.Fatal(http.ListenAndServe(":8080", serveHTTP(middleware.LoggingMiddleware(mux))))
}
func serveHTTP(handler http.Handler) http.Handler {