company crud test task
Docker - https://docs.docker.com/engine/install Go 1.17 - https://go.dev
The project follows Package Oriented Design (aka Domain Oriented Design). An alternative layout with horizontal packages (mongo, service, handler, etc.) could also be used.
- cmd - executables
- company - public project files
- internal - internal project files
- migrations - mongoDB migrations
- mongo - mongoDB init scripts
- auth - JWT auth files
To run all tests run make test
. To run linters run make lint
.
To run e2e tests run the project execute make start
and then make test_e2e
.
To build the project execute make build
.
To run the project locally execute make start
.
Create new migration: ./mongo/migrate.sh create -ext json -seq -dir path/to/migrations/ migration_name
.
Run migrations: make migrate