added health routes

This commit is contained in:
2026-01-05 14:41:25 +08:00
parent c69a33dfd8
commit 81d3c5a3bd
4 changed files with 90 additions and 2 deletions
+5 -1
View File
@@ -9,6 +9,10 @@ import (
)
func SetupRoutes(router *mux.Router, db *sql.DB) {
router.HandleFunc("/health", handlers.HealthHandler).Methods("GET")
router.HandleFunc("/ready", handlers.ReadyHandler).Methods("GET")
authRoutes := router.PathPrefix("/v1/auth").Subrouter()
authRoutes.HandleFunc("/login", handlers.GoogleLogin).Methods("GET")
authRoutes.HandleFunc("/callback", handlers.GoogleCallback).Methods("GET")
@@ -16,7 +20,7 @@ func SetupRoutes(router *mux.Router, db *sql.DB) {
authRoutes.HandleFunc("/logout", handlers.LogoutHandler).Methods("GET")
// authRoutes.HandleFunc("/microsoft/login", handlers.MicrosoftLogin).Methods("GET")
// authRoutes.HandleFunc("/microsoft/callback", handlers.MicrosoftCallback).Methods("GET")
// authRoutes.HandleFunc("/microsoft/callback", handlers.MicrosotCallback).Methods("GET")
router.PathPrefix("/swagger/").Handler(httpSwagger.WrapHandler)
}