Skip to content

cmin764/deep-ice

Repository files navigation

Deep Ice

E-commerce platform selling ice cream

Check out this use-case to see how to quickly order some ice cream.

Run

Run the service stack locally with Docker Compose:

docker-compose up # --build

Now go to http://localhost/docs to see the API docs. You can test it right in the browser.

For APIs requiring authentication, make sure to click the "Authorize" button first and place inside any of the test credentials as following:

  • username: <e-mail address> ([email protected])
  • password: <mocked password> (cosmin-password)

To bring the stack down and cleanup resources:

docker-compose down --rmi all --volumes --remove-orphans

Development

Ensure you have Python 3, Invoke and UV installed, then in the project dir run the following below to install dependencies and run the API server in development mode.

inv run-server -d

The server requires PostgreSQL and Redis up and running.
Ensure proper configuration by copying .env.template into .env first, then change the file to suit your setup.

Don't forget to run migrations first and a task queue worker to deal with deferred tasks:

inv run-migrations
inv run-worker -d

Testing

inv test

Formatting

inv format-check -f

Linting

inv format-check
inv lint

Type-checking

inv type-check

Alternatively, you can run inv check-all to run all checks without affecting the code.

Check this ToDo list for further improvements and known caveats.

About

E-commerce platform selling ice cream

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages