CHANGE: Switched The Interface From HTML to JSON API
Build, Push and Deploy CMS / build-push-deploy (push) Successful in 1m53s
Build, Push and Deploy CMS / build-push-deploy (push) Successful in 1m53s
This commit is contained in:
+3
-6
@@ -78,13 +78,10 @@ func runServer() {
|
||||
|
||||
mux := http.NewServeMux()
|
||||
|
||||
mux.Handle("GET /static/", http.StripPrefix("/static/", http.FileServer(http.Dir("static"))))
|
||||
mux.HandleFunc("GET /", handlers.Home)
|
||||
mux.HandleFunc("GET /api/hello", handlers.Hello)
|
||||
mux.HandleFunc("GET /health", handlers.Health)
|
||||
mux.HandleFunc("GET /videos/new", handlers.NewVideo)
|
||||
mux.HandleFunc("POST /videos/presign", handlers.PresignVideoUpload)
|
||||
mux.HandleFunc("POST /videos", handlers.CompleteVideoUpload)
|
||||
mux.HandleFunc("GET /api/categories", handlers.ListCategories)
|
||||
mux.HandleFunc("POST /api/videos/presign", handlers.PresignVideoUpload)
|
||||
mux.HandleFunc("POST /api/videos", handlers.CompleteVideoUpload)
|
||||
|
||||
addr := ":8081"
|
||||
log.Printf("listening on %s", addr)
|
||||
|
||||
Reference in New Issue
Block a user