mirror of
https://gitee.com/gokins/gokins.git
synced 2024-11-30 02:07:52 +08:00
14 lines
192 B
Go
14 lines
192 B
Go
|
package main
|
||
|
|
||
|
import "github.com/gin-gonic/gin"
|
||
|
|
||
|
func main() {
|
||
|
r := gin.Default()
|
||
|
r.GET("/ping", func(c *gin.Context) {
|
||
|
c.JSON(200, gin.H{
|
||
|
"message": "pong",
|
||
|
})
|
||
|
})
|
||
|
r.Run(":8050")
|
||
|
}
|