Clone this repo and start your API development.
- Build Docker Images
docker-compose build api
- Run Docker Container
docker-compose up api
- Start dependencies
docker-compose up -d db
- Start API with serve:
go run main.go serve
- Integrated with PostgreSQL
- Integrated with migration package.
- Run migration:
go run main.go migrate
- Reset migration:
go run main.go migrate --reset
- courses
Columns | Description |
---|---|
id | Primary key of table |
name | Name of the course |
description | Course description |
author | Author of description |
created_at | Created time of course |
- HTTP Router - https://github.com/go-chi/chi
- PostgreSQL - https://github.com/jackc/pgx
- Logging - https://github.com/sirupsen/logrus
- Cli - https://github.com/spf13/cobra
- Configuration - https://github.com/spf13/viper