feat: make Supervisor logfile path configurable via environment variable
All checks were successful
Build and Push Docker Image to Gitea / build-and-push (push) Successful in 1m12s

Added SUPERVISOR_LOGFILE environment variable to configure the path to
the Supervisor main logfile for reading via XML-RPC.

Changes:
- Added SUPERVISOR_LOGFILE to .env.example with default path
- Removed getLogfilePath() method and cachedLogfilePath field from SupervisorClient
- Updated readLog() to use environment variable with fallback chain:
  1. Explicitly provided logfilePath parameter
  2. SUPERVISOR_LOGFILE environment variable
  3. Default: /var/log/supervisor/supervisord.log
- Added debug logging to readLog() for troubleshooting

This allows users to configure the correct logfile path for their
Supervisor installation when using the custom 3-parameter XML-RPC
readLog implementation.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-11-23 22:46:53 +01:00
parent 145d37193c
commit c50274452c
2 changed files with 7 additions and 37 deletions

View File

@@ -11,6 +11,10 @@ SUPERVISOR_PORT=9001
# SUPERVISOR_USERNAME=user
# SUPERVISOR_PASSWORD=pass
# Optional: Path to supervisord main logfile (for reading via XML-RPC)
# Default: /var/log/supervisor/supervisord.log
# SUPERVISOR_LOGFILE=/var/log/supervisor/supervisord.log
# Logging Configuration
# Log level: debug, info, warn, error (default: info in prod, debug in dev)
LOG_LEVEL=info