- In order to run the project, execute in the project root directory
docker-compose up
. There may be a problem with PostgreSQL when running project with docker for the first time. PostgreSQL may be unavailable for the first time of runningdocker-compose up
. Terminating it and runningdocker-compose up
again solves the problem. - There is a script
scripts/initial.py
for initializing database with the data mentioned in the project description. No need to execute it, since it's included in docker command. But it can be run as follows:python manage.py runscript initial
- In order to start the demo, first run
workers.py
and thenorder_populator.py
in another shell.docker-compose exec web sh cd demo python workers.py
docker-compose exec web sh cd demo python order_populator.py
black
andisort
are used for linting.- Tests for services and all available endpoints are written.
- CI/CD integrated with the project using Github Action. It checks linting and runs tests.
/users/register/
and/users/token/
endpoints are throttled. Both can be accessed separately five times per minute.- Localization is supported within the project and Turkish & English are supported languages. When
you add
Accept-Language: en-us
orAccept-Language: tr-tr
header to the request, labels are translated to preferred language. RedisPubSub
is written and used for the project.DummyPubSub
is also written in order to configure it defaultPubSub
class for pipeline tests.- Passwords for all users are set to 12345