feat: load printer configuration from .env

Configure the 80 mm thermal printer (576 dots) via a committed .env file,
loaded at startup with dotenvy. Real environment variables take precedence.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
bankosegger
2026-11-11 15:00:03 +01:00
parent eae81bb052
commit a2b83744db
5 changed files with 27 additions and 1 deletions

10
.env Normal file
View File

@@ -0,0 +1,10 @@
# Photobooth configuration, loaded from the directory the app is started from.
# Variables already set in the environment (e.g. by systemd) take precedence.
# Thermal printer (ESC/POS). Remove or leave empty to disable printing.
# A device path for USB/serial printers, or tcp://host[:port] for network
# printers (port defaults to 9100).
PHOTOBOOTH_PRINTER=/dev/usb/lp0
# Printable width in dots: 576 for 80 mm paper (384 for 58 mm).
PHOTOBOOTH_PRINTER_DOTS=576