Skip to content

Virtual Recipe Box is a Dockerised recipe manager that ships with both a guided CLI and a lightweight Flask web UI. Recipes live in a local SQLite database, while PDFs and exports are stored beside the code (bind-mount the folder to persist them on the host).

Notifications You must be signed in to change notification settings

Cybonix/virtual_recipe_box

Repository files navigation

Virtual Recipe Box

Virtual Recipe Box is a Dockerised recipe manager that ships with both a guided CLI and a lightweight Flask web UI.
Recipes live in a local SQLite database, while PDFs and exports are stored beside the code (bind-mount the folder to persist them on the host).

Features

  • Preloaded starter recipes to explore the interface immediately
  • Add new recipes manually or by importing local/remote PDF files
  • Automatic text extraction with optional clean-up before saving
  • Rich filtering (term, ingredient, tags, PDF presence) in both CLI and web UI
  • Full-featured web experience to create, edit, delete, and export recipes
  • Edit/delete recipes and manage their associated PDFs and images
  • Export any recipe into a formatted PDF document for sharing

Requirements

  • Docker Engine 20.10+ (or compatible runtime)
  • Optional bind-mounted host directory for database and file persistence

Build the Container Image

docker build -t virtual-recipe-box -f docker/Dockerfile .

Run the CLI Menu

docker run --rm -it -v "$(pwd)":/app virtual-recipe-box

Inside the menu, choose Search Recipes to combine filters such as ingredient keywords, tag selections, and PDF availability.

The application stores runtime artefacts inside the mounted directory:

  • recipes.db – SQLite database containing recipe metadata
  • pdf_recipe_files/ – managed storage for recipe PDFs
  • exported_recipes/ – generated PDFs from the export option
  • app.log – error log for troubleshooting

Launch the Web UI

docker run --rm -it -p 8000:8000 -v "$(pwd)":/app virtual-recipe-box python virtual_recipe_box.py --web

The web experience mirrors the CLI: add, import, edit, delete, filter, and export recipes all from the browser. Linked detail pages offer inline PDF access and quick exports.
Visit http://localhost:8000 after starting the container.

Importing Recipe PDFs

  • Supply a file path that is visible inside the container (relative paths work when the repository is bind-mounted).
  • Alternatively, paste an HTTP/HTTPS URL; the PDF is downloaded into pdf_recipe_files/.
  • The importer extracts text, guesses ingredients/instructions, and lets you tweak them before saving.

Sample Data

An initial set of recipes (sample_recipes.json) is automatically loaded the first time the database is created.
Customise or extend this file before the first run to tailor the starter content.

Database Health Check

docker run --rm -it -v "$(pwd)":/app virtual-recipe-box python connection_Tester.py

The helper prints the total recipe count and up to five sample entries.

Contributing & Testing

  • Exercise both the CLI and the web UI when making changes.
  • docker run --rm -v "$(pwd)":/app virtual-recipe-box python -m compileall virtual_recipe_box.py connection_Tester.py ensures the Python modules still compile.
  • Keep dependency changes minimal and document behavioural updates here.

About

Virtual Recipe Box is a Dockerised recipe manager that ships with both a guided CLI and a lightweight Flask web UI. Recipes live in a local SQLite database, while PDFs and exports are stored beside the code (bind-mount the folder to persist them on the host).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published