forked from ebhomengo/niki
27 lines
420 B
Go
27 lines
420 B
Go
package main
|
|
|
|
import (
|
|
"time"
|
|
|
|
"git.gocasts.ir/ebhomengo/niki/patientapp"
|
|
"git.gocasts.ir/ebhomengo/niki/patientapp/config"
|
|
"git.gocasts.ir/ebhomengo/niki/patientapp/repository/mysql"
|
|
)
|
|
|
|
func main() {
|
|
db := mysql.DataBase{}
|
|
|
|
cfg := config.Config{
|
|
Port: 8080,
|
|
Cors: config.Cors{
|
|
AllowOrigins: []string{"*"},
|
|
},
|
|
ShutDownCtxTimeout: 5 * time.Second,
|
|
}
|
|
|
|
app := patientapp.Setup(cfg, &db)
|
|
|
|
app.Start()
|
|
|
|
}
|