mirror of
https://github.com/mgerb/mywebsite
synced 2026-01-12 02:42:48 +00:00
server set up with app engine
This commit is contained in:
23
server.go
Normal file
23
server.go
Normal file
@@ -0,0 +1,23 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
|
||||
"mywebsite/server/controller/api"
|
||||
"mywebsite/server/db"
|
||||
"mywebsite/server/route"
|
||||
"mywebsite/server/utils"
|
||||
)
|
||||
|
||||
func init() {
|
||||
configurations := utils.ReadConfig()
|
||||
|
||||
db.Configure(configurations.Database)
|
||||
api.Configure(configurations.Api)
|
||||
|
||||
db.Mongo.Connect()
|
||||
|
||||
router := route.Routes()
|
||||
|
||||
http.Handle("/", router)
|
||||
}
|
||||
Reference in New Issue
Block a user