[feat] add pkgs, dockerfile, makefile

This commit is contained in:
Jay
2020-08-16 01:21:27 +08:00
parent f92efa91fc
commit 77cc488d89
16 changed files with 482 additions and 5 deletions
+22
View File
@@ -0,0 +1,22 @@
package routes
import (
"net/http"
"github.com/gin-gonic/gin"
)
func New() *gin.Engine {
e := gin.New()
e.Use(gin.Logger())
e.Use(gin.Recovery())
return e
}
func SetRoute(e *gin.Engine) {
e.GET("/", func(c *gin.Context) {
c.String(http.StatusOK, "ok")
})
}