project for learning golang with gin framework and gorm as ORM
- Golang go1.22.2
- Gin Framework
- Gorm
- PostgreSQL
-
pull repository
git clone git@github.com:abdul15irsyad/gin-gorm-rest-api.git cd gin-gorm-rest-api
-
install dependencies
go mod download
-
configsure environment, copy from
.env.example
to.env
and adjust to your setup like database, port, jwt secret, etc.cp .env.example .env
-
run the project
go run main.go
or with air (live reload)
air
-
run the seeder for dummy datas
go run cmd/seed.go