Adds dummy status endpoint
This commit is contained in:
parent
92aaba7a5b
commit
833b2759f4
1 changed files with 16 additions and 2 deletions
18
main.go
18
main.go
|
|
@ -1,7 +1,21 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import "fmt"
|
import (
|
||||||
|
"net/http"
|
||||||
|
|
||||||
|
"github.com/gin-gonic/gin"
|
||||||
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
fmt.Println("Init freed application")
|
r := gin.Default()
|
||||||
|
|
||||||
|
r.GET("/status", func(c *gin.Context) {
|
||||||
|
c.JSON(http.StatusOK, gin.H{
|
||||||
|
"application": "freed",
|
||||||
|
"version": "0.0.1",
|
||||||
|
"status": "up",
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
r.Run(":42069")
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue