This repository has been archived on 2026-03-28. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
api/main.go
2022-12-25 23:14:45 +01:00

24 lines
358 B
Go

package main
import (
"gractwo-api/database"
"gractwo-api/router"
"github.com/joho/godotenv"
)
func main() {
//line valid only on dev. ignore
godotenv.Load("local.env")
//init database
database.CreateConnection()
//Init api
router := router.InitRouter()
err := router.Run(":2021")
if err != nil {
panic("failed to connect database")
}
}