PyRecipe

A Cookbook Designed with Python!

GPL-3.0 License

Stars
3
Committers
3

PyRecipe

A Cookbook Designed with Python!

Under Developement

  • This project is under development at the moment.
  • The aim of this project is to have a Flask & MongoDB web app.
  • To work on the project, below you'll find some installation instructions.

Installation

  1. Install the MongoDB Server - Community Edition
  2. Install the poetry package management system.
  3. Create a virtual environment with python 3.6+.
  4. Clone this repository.
$ git clone https://github.com/trp07/PyRecipe.git
  1. Install the project in development mode.
$ cd PyRecipe
$ poetry install
  1. Run Tests
$ pytest -v
  1. If tests successfully pass, then begin contributing in your feature branch.

Running in Docker

To run this in Docker, use the following commands. You shouldn't need to run build and poetry install except on first run.

docker build -t pyrecipe .
docker run --rm -itv $(pwd):/PyRecipe -w PyRecipe bash
poetry install
nohup /usr/bin/mongod &
pytest -v

This still needs work. Improvements that are still needed are:

  • All dependencies to be installed in the build step without having all the files persist, so build doesn't have to happen often.
  • The mongo daemon to be run in the background by default. Though this belongs in a separate container really.

If these improvements are made, we should then be able to just run:

docker run --rm -itv $(pwd):/PyRecipe -w PyRecipe pytest -v