mirror of
https://github.com/maziggy/bambuddy.git
synced 2026-09-30 19:21:33 +02:00
- Add user directive to docker-compose.yml using PUID/PGID env vars - Allows container to run as host user, fixing permission issues with bind-mounted volumes (e.g., ./virtual_printer) - Add chmod 777 to /app/data and /app/logs in Dockerfile for non-root compatibility - Usage: PUID=$(id -u) PGID=$(id -g) docker compose up -d Note: Existing named volumes (bambuddy_logs, bambuddy_data) created by previous root containers may need to be removed or have permissions fixed manually.
38 lines
1.3 KiB
YAML
38 lines
1.3 KiB
YAML
services:
|
|
bambuddy:
|
|
image: ghcr.io/maziggy/bambuddy:latest
|
|
build: .
|
|
# Usage:
|
|
# docker compose up -d → pulls pre-built image from ghcr.io
|
|
# docker compose up -d --build → builds locally from source
|
|
container_name: bambuddy
|
|
# Run as current user to avoid permission issues with mounted volumes
|
|
# Override with: PUID=$(id -u) PGID=$(id -g) docker compose up -d
|
|
user: "${PUID:-1000}:${PGID:-1000}"
|
|
#
|
|
# LINUX: Use host mode for printer discovery and camera streaming
|
|
network_mode: host
|
|
#
|
|
# macOS/WINDOWS: Docker Desktop doesn't support host mode.
|
|
# Comment out "network_mode: host" above and uncomment "ports:" below.
|
|
# Note: Printer discovery won't work - add printers manually by IP.
|
|
#ports:
|
|
# - "${PORT:-8000}:8000"
|
|
volumes:
|
|
- bambuddy_data:/app/data
|
|
- bambuddy_logs:/app/logs
|
|
#
|
|
# Share virtual printer certs with native installation
|
|
# This ensures the slicer only needs to trust one CA certificate.
|
|
- ./virtual_printer:/app/data/virtual_printer
|
|
environment:
|
|
- TZ=Europe/Berlin
|
|
# Port BamBuddy runs on (default: 8000)
|
|
# Usage: PORT=8080 docker compose up -d
|
|
- PORT=${PORT:-8000}
|
|
restart: unless-stopped
|
|
|
|
volumes:
|
|
bambuddy_data:
|
|
bambuddy_logs:
|