Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sunmadeq/todo
A minimal To-Do application built with Go
https://github.com/sunmadeq/todo
clear-ar docker docker-compose dockerfile gin go golang golang-api golang-jwt golang-migrate golang-rest jwt jwt-authentication rest-api sql
Last synced: about 1 month ago
JSON representation
A minimal To-Do application built with Go
- Host: GitHub
- URL: https://github.com/sunmadeq/todo
- Owner: sunmadeq
- License: mit
- Created: 2024-08-19T09:20:32.000Z (3 months ago)
- Default Branch: master
- Last Pushed: 2024-08-19T09:33:10.000Z (3 months ago)
- Last Synced: 2024-10-02T05:21:04.732Z (about 1 month ago)
- Topics: clear-ar, docker, docker-compose, dockerfile, gin, go, golang, golang-api, golang-jwt, golang-migrate, golang-rest, jwt, jwt-authentication, rest-api, sql
- Language: Go
- Homepage:
- Size: 17.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# A minimal REST API for creating To-Do Lists
## The project covers the following concepts:
- developing web applications in Go, following the REST API design;
- working with the gin-gonic/gin framework;
- the Clean Architecture approach to building the application structure;
- dependency injection technique;
- working with the PostgreSQL database;
- working with Docker;
- generating migration files;
- configuring the app using the spf13/viper library;
- working with environment variables;
- authentication and authorization using JSON Web Tokens (JWTs) and Middleware;
- writing SQL queries;
- graceful shutdown.## To run the application:
Install Docker Desktop and run the following command:
```
docker compose up
```Install the Migrate utility and apply existing migrations to the database:
```
migrate -path ./schema -database "postgres://postgres:postgres@localhost:5432/postgres?sslmode=disable" up
```Run the application:
```
go run ./cmd/main.go
```