mirror of
https://github.com/pushbits/server.git
synced 2025-06-02 18:52:06 +02:00
Add health check for Docker image
This commit is contained in:
parent
3bdadd6029
commit
da1aa3c3b8
5 changed files with 37 additions and 0 deletions
|
@ -24,6 +24,7 @@ func Create(debug bool, cm *credentials.Manager, db *database.Database, dp *disp
|
|||
auth := authentication.Authenticator{DB: db}
|
||||
|
||||
applicationHandler := api.ApplicationHandler{DB: db, DP: dp}
|
||||
healthHandler := api.HealthHandler{DB: db}
|
||||
notificationHandler := api.NotificationHandler{DB: db, DP: dp}
|
||||
userHandler := api.UserHandler{AH: &applicationHandler, CM: cm, DB: db, DP: dp}
|
||||
|
||||
|
@ -42,6 +43,8 @@ func Create(debug bool, cm *credentials.Manager, db *database.Database, dp *disp
|
|||
applicationGroup.PUT("/:id", api.RequireIDInURI(), applicationHandler.UpdateApplication)
|
||||
}
|
||||
|
||||
r.GET("/health", healthHandler.Health)
|
||||
|
||||
r.POST("/message", auth.RequireApplicationToken(), notificationHandler.CreateNotification)
|
||||
|
||||
userGroup := r.Group("/user")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue