Skip to content

The project helps to create documents from templates using jinja tags (docxtpl) and get the results in docx/pdf.

License

Notifications You must be signed in to change notification settings

molodsom/docx-generator

Repository files navigation

GitHub Workflow Status GitHub Workflow Status Coverage badge GitHub

docx-generator

Quick start

  • Virtual environment: python3 -m venv venv
  • Unix-like: source venv/bin/activate
  • Windows: venv\Scripts\activate
  • Install dependencies: pip3 install -r requirements.txt
  • To use PDF: Install LibreOffice, and specify the path to the executable in the .env file with the LIBREOFFICE_BINARY environment variable
  • Run it: uvicorn main:app --reload

Docker

docker run -d -p 80:80 \
   -v /path/to/result:/result \
   -v /path/to/upload:/upload \
   -v /path/to/sqlite.db:/app/docx.db \
   -e DB_URL=sqlite:///docx.db \
   ghcr.io/molodsom/docx-generator:latest

It also supports postgresql:// and mysql+pymysql:// schemas.

Docker Compose

docker-compose up -d

About

The project helps to create documents from templates using jinja tags (docxtpl) and get the results in docx/pdf.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages