c66c19dc59
Local Docker Build (Dev) / build-dev (pull_request) Successful in 3s
Authentication Features: - Optional HTTP Basic Auth with session cookies for web interface protection - Configurable username/password with session timeout (default: 1 hour) - Selective route protection (web interface protected, webhooks/APIs remain public) - Authentication status display with logout functionality in web UI - Session cleanup and graceful logout with browser re-authentication prompt Configuration: - WEB_AUTH_ENABLED in .env (default: false - no breaking changes) - WEB_AUTH_USERNAME/WEB_AUTH_PASSWORD in .env.secrets - WEB_AUTH_SESSION_TIMEOUT configurable (5min-24h range) Development Tools: - Added debug_tv.py for TV series/episode debugging (series, season, episode levels) - Comprehensive episode data inspection with validation and sources breakdown - Complements existing debug_movie.py for complete media debugging coverage Technical Implementation: - SimpleAuthMiddleware with FastAPI integration - Session management with automatic cleanup - Authentication status API endpoints - Responsive CSS styling for auth UI elements - JavaScript functions for auth checking and logout
151 lines
4.9 KiB
Bash
151 lines
4.9 KiB
Bash
# ===========================================
|
|
# NFOGuard Configuration - CORRECTED VERSION
|
|
# ===========================================
|
|
# Main configuration file - safe to share for debugging
|
|
# Sensitive data (API keys, passwords) are in .env.secrets
|
|
|
|
# ===========================================
|
|
# MEDIA PATHS (REQUIRED) - FIXED
|
|
# ===========================================
|
|
# Container paths (what NFOGuard sees inside container)
|
|
MOVIE_PATHS=/media/Movies/movies,/media/Movies/movies6
|
|
TV_PATHS=/media/TV/tv,/media/TV/tv6
|
|
|
|
# Radarr paths (what Radarr sees on the host system)
|
|
RADARR_ROOT_FOLDERS=/mnt/unionfs/Media/Movies/movies,/mnt/unionfs/Media/Movies/movies6
|
|
|
|
# Sonarr paths (what Sonarr sees on the host system) - FIXED VARIABLE NAME AND PATHS
|
|
SONARR_ROOT_FOLDERS=/mnt/unionfs/Media/TV/tv,/mnt/unionfs/Media/TV/tv6
|
|
|
|
# Download detection paths (for identifying downloads vs existing files)
|
|
DOWNLOAD_PATH_INDICATORS=/downloads/,/nzbget/,/completed/,/sabnzbd/,/torrents/
|
|
|
|
# ===========================================
|
|
# DATABASE CONFIGURATION
|
|
# ===========================================
|
|
# NFOGuard Database Configuration (PostgreSQL - v2.6+)
|
|
# NOTE: For new installations, PostgreSQL is strongly recommended
|
|
# Set these values in .env.secrets for security:
|
|
# - DB_PASSWORD=your_secure_password
|
|
# - DB_USER=nfoguard (default)
|
|
|
|
# PostgreSQL Database Settings
|
|
DB_TYPE=postgresql
|
|
DB_HOST=nfoguard-db # Container name from docker-compose
|
|
DB_PORT=5432
|
|
DB_NAME=nfoguard
|
|
|
|
# Legacy SQLite Configuration (Deprecated in v2.6+)
|
|
# Only use for existing SQLite installations
|
|
# DB_PATH=/app/data/media_dates.db
|
|
|
|
# Log file directory
|
|
LOG_DIR=/app/data/logs
|
|
|
|
# ===========================================
|
|
# RADARR DATABASE CONNECTION (RECOMMENDED)
|
|
# ===========================================
|
|
# Direct database access for better performance
|
|
RADARR_DB_TYPE=postgresql
|
|
RADARR_DB_HOST=192.168.255.50
|
|
RADARR_DB_PORT=5432
|
|
RADARR_DB_NAME=radarr-main
|
|
RADARR_DB_USER=postgres
|
|
|
|
# ===========================================
|
|
# API CONNECTIONS (OPTIONAL)
|
|
# ===========================================
|
|
# API keys are stored in .env.secrets for security
|
|
RADARR_URL=http://radarr:7878
|
|
SONARR_URL=http://sonarr:8989
|
|
JELLYSEERR_URL=http://jellyseerr:5055
|
|
|
|
# ===========================================
|
|
# RELEASE DATE PROCESSING
|
|
# ===========================================
|
|
# Priority order for release date fallbacks (digital, physical, theatrical)
|
|
RELEASE_DATE_PRIORITY=digital,physical,theatrical
|
|
#RELEASE_DATE_PRIORITY=digital,theatrical,physical
|
|
ENABLE_SMART_DATE_VALIDATION=true
|
|
MAX_RELEASE_DATE_GAP_YEARS=10
|
|
|
|
# Prefer API release dates over file modification dates for manual imports
|
|
PREFER_RELEASE_DATES_OVER_FILE_DATES=true
|
|
|
|
# Disable file date fallback completely (recommended for clean imports)
|
|
ALLOW_FILE_DATE_FALLBACK=false
|
|
|
|
# TMDB country for regional release date preferences
|
|
TMDB_COUNTRY=US
|
|
|
|
# ===========================================
|
|
# NFO FILE MANAGEMENT
|
|
# ===========================================
|
|
# Create/update .nfo files
|
|
MANAGE_NFO=true
|
|
|
|
# Update file modification times to match import dates
|
|
FIX_DIR_MTIMES=true
|
|
|
|
# Add lockdata tags to prevent metadata overwrites
|
|
LOCK_METADATA=true
|
|
|
|
# Brand name in NFO comments
|
|
MANAGER_BRAND=NFOGuard
|
|
|
|
# ===========================================
|
|
# PROCESSING BEHAVIOR
|
|
# ===========================================
|
|
# Movie date update strategy
|
|
MOVIE_DATE_UPDATE_MODE=overwrite
|
|
MOVIE_PRESERVE_EXISTING=false
|
|
|
|
# When to update existing dates (always, missing_only, never)
|
|
UPDATE_MODE=always
|
|
|
|
# File modification time behavior (update, leave_alone)
|
|
MTIME_BEHAVIOR=update
|
|
|
|
# Manual scan priority: use existing NFO dates for speed vs check APIs for accuracy
|
|
# false (default) = Check external APIs first, use NFO as fallback (slower but accurate)
|
|
# true = Use NFO dates immediately without API checks (faster but may use wrong dates)
|
|
MANUAL_SCAN_PRIORITIZE_NFO=false
|
|
|
|
# ===========================================
|
|
# PERFORMANCE & BATCHING
|
|
# ===========================================
|
|
# Delay before processing batched events (seconds)
|
|
BATCH_DELAY=5.0
|
|
|
|
# Maximum concurrent series processing
|
|
MAX_CONCURRENT_SERIES=3
|
|
|
|
# API timeout in seconds
|
|
TIMEOUT_SECONDS=45
|
|
|
|
# ===========================================
|
|
# DEBUGGING
|
|
# ===========================================
|
|
# Enable verbose logging (true/false)
|
|
DEBUG=false
|
|
|
|
# Enable path mapping debug output (true/false)
|
|
PATH_DEBUG=false
|
|
|
|
# Suppress TVDB API warnings (true/false) - TVDB failures are common and non-critical
|
|
SUPPRESS_TVDB_WARNINGS=true
|
|
|
|
# ===========================================
|
|
# WEB INTERFACE AUTHENTICATION
|
|
# ===========================================
|
|
# Enable web interface authentication (default: false)
|
|
WEB_AUTH_ENABLED=false
|
|
|
|
# Session timeout in seconds (default: 3600 = 1 hour)
|
|
WEB_AUTH_SESSION_TIMEOUT=3600
|
|
|
|
# ===========================================
|
|
# SERVER CONFIGURATION
|
|
# ===========================================
|
|
# Port for webhook server
|
|
PORT=8080 |