Skip to content

Semaffor/go_todo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Plain todo API

Pure Api with CRUD operations with lists and tasks with using JWT-auth.

To run on local machine

Docker (In process)


Manually


First off, clone repository:

https://github.com/Semaffor/go_todo/

Then, in main directory create file .env and put applicable values for following keys: DB_PASSWORD, TOKEN_VALID_TIME_HOURS and SIGN_KEY.

Recheck params in `configs/configs.yaml

Run migration file from the main directory

migrate -path ./schema -database 'postgres://postgres:qwerty@localhost:[port]/postgres?sslmode=disable' up

Finally start the app

go run cmd/main.go

Docs

http://localhost:8000/swagger/

Databse schema

image