Dynamic user segmentation service for AvitoTech internship
Table of Contents
This is repository for test task
from AvitoTech
. Service give an HTTP API
with JSON
format in request
and response
. All project written in Golang language with PostgreSQL database.
This is short instruction about how to start to use this servise in your environment.
This is an list of needed software and how to install them.
- Golang language
sudo apt install golang
- Docker
sudo apt install docker docker.io
systemctl enable docker
systemctl start docker
- Migrate utilite
curl -s https://packagecloud.io/install/repositories/golang-migrate/migrate/script.deb.sh | sudo bash
sudo apt-get install migrate
-
Clone the repo
git clone https://github.com/github_username/repo_name.git
-
Install software above
-
Write the folow command
make build && make run
-
If service runs for first time, migrations must be done:
make migrate
Whole API Endpoints avalieble at POSTMAN:
https://www.postman.com/crimson-resonance-324941/workspace/avitotech-intershiptest/collection/27188643-63e09760-9e57-43ea-8aa0-d9c6520ee754?action=share&creator=27188643
As Service installed and runned swagger docs also avalieble at:
http://SERVER_HOST:SERVER_PORT/swagger/index.html
To start service:
make build && make run
To stop service:
make stop
- API Service
- Swagger docs
- Test covarage
- Extra task one
- Extra task two
- Extra task three
- Integrate JWT tockens
- Integrate NoSQL base like Redis
Alexey Kirichek - rokirokz@mail.ru