Skip to content

fr13n8/todo-app

Repository files navigation

REST API TODO in Go

Development tools and principles

  • Go Web Applications following the REST API Design
  • Working with the framework gin-gonic/gin
  • The Clean Architecture approach to building an application structure. Dependency injection technique
  • Working with Postgres DB. Running from Docker. Generation of migration files
  • Application configuration using the library spf13/viper. Working with environment variables
  • Working with BD using the library: sqlx
  • Auth with JWT(get and refresh) and middleware
  • Write SQL queries
  • Graceful Shutdown

DEMO

todo-app

How to run

make build && make run

If app startet first time need to run migrations

make migrate

All commands

  • Build
make build
  • Run
make run
  • Run Tests
make test
  • Migrate up
make migrate_up
  • Migrate down
make migrate_down
  • Generate swagger documentation
make swag
  • Generate mocks
cd pkg/service && go generate