Golang Gin Hexagonal Architecture Implementation with Docker, Redis, Github Actions, RabbitMQ, Postgres and GORM.
-
Make sure your Go version is 1.24 or higher
go -version
-
Copy
.env.example
to.env
and adjust accordinglycp .env.example .env
-
Install the required Go dependencies
go mod download
-
Run the program
./run.sh
Auth:
- JWT
- OAuth2
RBAC:
- user
- admin
APIs:
- Store API (user)
- Payment gateway
- User CRUD (admin)
- Product CRUD (admin)
API Framework:
- Gin
DB:
- Postgres
- GORM
Caching:
- Redis
Message Broker:
- RabbitMQ
CI / CD:
- Github Action
Libraries:
- github.com/gin-gonic/gin
- github.com/githubnemo/CompileDaemon
- github.com/joho/godotenv
- gorm.io/gorm
- gorm.io/driver/postgres
- github.com/google/uuid
- github.com/golang-jwt/jwt/v5