Files
Spoolman/.env.example
T
Donkie 1262eb664a Document SPOOLMAN_LEGACY_CLIENT in .env.example
The var is the operator's rollback path if the new client misbehaves, but it was
only discoverable by reading env.py or the Dockerfile. Nothing else documents
Spoolman's env vars, so .env.example is the place.
2026-07-28 20:56:17 +02:00

94 lines
3.3 KiB
Bash

# DB Type: sqlite, mysql, postgres, cockroachdb
# Default if not set: sqlite
#SPOOLMAN_DB_TYPE=sqlite
# DB Setup, if not using sqlite
# Database hostname
#SPOOLMAN_DB_HOST=
# Database port
#SPOOLMAN_DB_PORT=
# Database name
#SPOOLMAN_DB_NAME=
# Database login username
#SPOOLMAN_DB_USERNAME=
# Path of file which contains the database password. Can be used instead of SPOOLMAN_DB_PASSWORD if desired.
#SPOOLMAN_DB_PASSWORD_FILE=
# Database login password
#SPOOLMAN_DB_PASSWORD=
# Query parameters for the database connection, e.g. set to `unix_socket=/path/to/mysql.sock` to connect using a MySQL socket.
#SPOOLMAN_DB_QUERY=
# Logging level: DEBUG, INFO, WARNING, ERROR, CRITICAL
# Logs will only be reported if the level is higher than the level set here
# Default if not set: INFO
#SPOOLMAN_LOGGING_LEVEL=INFO
# Automatic nightly backup for SQLite databases
# Default if not set: TRUE
#SPOOLMAN_AUTOMATIC_BACKUP=TRUE
# Data directory, where the SQLite database is stored
# Default if not set: /home/<user>/.local/share/spoolman
#SPOOLMAN_DIR_DATA=/home/pi/spoolman_data
# Backup directory, where the SQLite database backups are stored
# Default if not set: /home/<user>/.local/share/spoolman/backups
#SPOOLMAN_DIR_BACKUPS=/home/pi/spoolman_data/backups
# Log directory
# Default if not set: /home/<user>/.local/share/spoolman
#SPOOLMAN_DIR_LOGS=/home/pi/spoolman_data
# Host and port to listen on
SPOOLMAN_HOST=0.0.0.0
SPOOLMAN_PORT=7912
# Change base path
# Set this if you want to host Spoolman at a sub-path
# If you want the root to be e.g. myhost.com/spoolman
# Then set this to /spoolman
#SPOOLMAN_BASE_PATH=
# Enable Collect Prometheus metrics at database
# Default: FALSE
#SPOOLMAN_METRICS_ENABLED=TRUE
# Collect items (filaments, materials, etc.) from an external database
# Set this to a URL of an external database. Set to an empty string to disable
# Default: https://donkie.github.io/SpoolmanDB/
#EXTERNAL_DB_URL=https://myhost.com/spoolmandb/
# Sync interval in seconds, set to 0 to disable automatic sync. It will only sync on start-up then.
# Default: 3600
#EXTERNAL_DB_SYNC_INTERVAL=3600
# Display name for the external database, shown in the UI.
# Set this to match your own catalog if you changed EXTERNAL_DB_URL above.
# Default: SpoolmanDB
#EXTERNAL_DB_NAME=SpoolmanDB
# Serve the previous (React) web client instead of the current one
# Both clients ship in the image and talk to the same API, so this is a safe
# rollback if the current client misbehaves on your setup. Your data is untouched
# either way. Please report the problem so it can be fixed.
# Default: FALSE
#SPOOLMAN_LEGACY_CLIENT=TRUE
# Enable debug mode
# If enabled, the client will accept requests from any host
# This can be useful when developing, but is also a security risk
# Default: FALSE
#SPOOLMAN_DEBUG_MODE=TRUE
# UID and GID of the user in the docker container
# These only make sense if you are running Spoolman in a docker container
# Default if not set: 1000
#PUID=1000
#PGID=1000
# Allows CORS ORIGIN.
# Use the https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/Access-Control-Allow-Origin semantics
# separated by commas
# for example to allow request from source1.domain.com on port p1 and source2.domain.com on port p2
# SPOOLMAN_CORS_ORIGIN=source1.domain.com:p1, source2.domain.com:p2
# to allow from any
# SPOOLMAN_CORS_ORIGIN=*