My solution for RAKT test task.
Build docker images
docker compose build
Start container with Database and wait ~10 seconds
docker compose up -d db
Then apply migrations, run tests to check application and load data from CSV file
docker compose run app python manage.py migrate
docker compose run app python manage.py test
docker compose run app python manage.py load_data food-truck-data.csv
Finally start application
docker compose up -d app
And open Swagger or Redoc in your browser to see API documentation.
Note: Authentication is not required for this task. You may simply press Try it out
button, set query parameters if needed and then Execute
.
For testing purposes you may take coordinates somewhere in San Francisco.
Example: lat=37.775912, lon=-122.450759