We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3602036 commit de6902dCopy full SHA for de6902d
1 file changed
pkg/server/server.go
@@ -22,6 +22,7 @@ func SetUpRouter() *gin.Engine {
22
v1.GET("/configuration", serverFunc(configuration))
23
v1.GET("/applications", serverFunc(listApplications))
24
v1.POST("/context/configuration", serverFunc(contextConfiguration))
25
+ v1.POST("/shutdown", serverFunc(shutdown))
26
}
27
return r
28
@@ -54,6 +55,15 @@ func healthcheck(c *gin.Context) {
54
55
c.String(http.StatusOK, "OK")
56
57
58
+func shutdown(c *gin.Context) error {
59
+ if err := syncGit(); err != nil {
60
+ return err
61
+ }
62
+
63
+ c.String(http.StatusOK, "OK")
64
+ return nil
65
+}
66
67
func teardown() error {
68
return syncGit()
69
0 commit comments