Skip to content

Latest commit

 

History

History
95 lines (72 loc) · 2.78 KB

README.md

File metadata and controls

95 lines (72 loc) · 2.78 KB

Backend Boilerplate with GO (Gin-gonic)

author PRs Welcome Build Status Go Report Card

당신이 Go 프로젝트를 빠르게 시작할수 있도록 도와줄께요!

Inspired by Covenant Ko


📚 Tech Stack

  • Go
  • Gin-gonic
  • GORM
  • Go Queryset
  • Swagger
  • MySQL
  • Docker
  • Travis CI
  • Deepsource Go

How it works

.
├── main.go
├── common
│   ├── utils.go              // small tools function
├── docs                      // automatically generated file by swagger
├── handler
│   ├── memo.go               // business logic
├── models
│   ├── autogenerated_memo.go // automatically generated file by gogqueryset
│   ├── database.go           // initial database setup
│   ├── memo.go               // memo models define & DB operation
├── responses
│   ├── memos.go              // define responses format 
├── responses
│   ├── memos.go              // define request format 
├── routers
│   ├── routers.go            // grouping URI
│       ├── v1
│           ├── router.go     // router binding

Generate Go-queryset

goqueryset -in {fileName}

🔧 Run the Applications

# Move to directory
$ cd workspace

# Clone into YOUR $GOPATH/src
$ git clone https://github.com/KoEonYack/Boilerplate-CRUD-GO.git

# Docker compose 
$ docker-compose up -d
# Run Case 1
$ go run main.go

# Run Case 2 
# Docker build
$ docker build . -t boilerplate-crud  

# Docker run
$ docker run -p 8080:8080 boilerplate-crud

📄 Reference

License