diff options
| author | Arda Serdar Pektezol <1669855+pektezol@users.noreply.github.com> | 2022-10-22 19:07:14 +0300 |
|---|---|---|
| committer | Arda Serdar Pektezol <1669855+pektezol@users.noreply.github.com> | 2022-10-22 19:07:14 +0300 |
| commit | d963c3f40f075c05d70af32f44ed2bec8e00bc37 (patch) | |
| tree | 33a362746201ebec46e7c741e40a530d5f32e38b /main.go | |
| download | lphub-d963c3f40f075c05d70af32f44ed2bec8e00bc37.tar.gz lphub-d963c3f40f075c05d70af32f44ed2bec8e00bc37.tar.bz2 lphub-d963c3f40f075c05d70af32f44ed2bec8e00bc37.zip | |
init
Diffstat (limited to 'main.go')
| -rw-r--r-- | main.go | 14 |
1 files changed, 14 insertions, 0 deletions
| @@ -0,0 +1,14 @@ | |||
| 1 | package main | ||
| 2 | |||
| 3 | import ( | ||
| 4 | "github.com/gin-gonic/gin" | ||
| 5 | "github.com/pektezol/leastportals/backend/controllers" | ||
| 6 | ) | ||
| 7 | |||
| 8 | func main() { | ||
| 9 | if controllers.GetEnvKey("ENV") == "PROD" { | ||
| 10 | gin.SetMode(gin.ReleaseMode) | ||
| 11 | } | ||
| 12 | router := gin.Default() | ||
| 13 | router.Run(":4000") | ||
| 14 | } | ||