Configuration
HD Homey is designed to be simple to configure with sensible defaults. Most configuration happens through environment variables and the web interface.
Configuration Methods
Environment Variables
The primary method for configuring HD Homey behavior, security, and runtime options.
View All Environment Variables →
Key variables you'll need:
AUTH_SECRET- Required for session encryptionHD_HOMEY_PROXY_HOST- Optional: Your external URL (auto-detects if blank)HD_HOMEY_DB_PATH- Optional: Database file path (default:./data/db/hd_homey.db)HD_HOMEY_TRANSCODE_DIR- Optional: Transcoding directory (auto-configured if blank)FFMPEG_PATH- Optional: FFmpeg location (auto-detected from PATH)
Database Configuration
HD Homey uses SQLite for data storage with automatic migrations.
Covers:
- Database location and structure
- Backup strategies
- Migration management
- Maintenance tasks
Web Interface Settings
Many features can be configured through the HD Homey web interface:
- Tuner Settings: Add/edit HDHomeRun devices
- Channel Management: Update channel lineups
- User Management: Create/modify user accounts
- Transcoding Options: Configure video encoding settings
- Stream Security: Manage stream token settings
Configuration Examples
Docker Compose (Recommended)
yaml
services:
hd-homey:
image: ghcr.io/shaunburdick/hd-homey:latest
environment:
AUTH_SECRET: your-secret-here
# HD_HOMEY_PROXY_HOST: https://tv.example.com # Optional - auto-detects if blank
volumes:
- ./data:/app/data
ports:
- "3000:3000"Environment File (.env)
bash
# Required
AUTH_SECRET=your-generated-secret
# Optional - Use defaults and auto-detection
# HD_HOMEY_PROXY_HOST= # Auto-detects from request
# HD_HOMEY_DB_PATH=./data/db/hd_homey.db # Default location
# HD_HOMEY_TRANSCODE_DIR= # Defaults to ${HD_HOMEY_DB_PATH}/transcoding
NODE_ENV=production
LOG_LEVEL=infoGenerate a secure AUTH_SECRET:
bash
openssl rand -base64 32Advanced Configuration
Reverse Proxy Setup
If you're deploying HD Homey behind a reverse proxy (nginx, Caddy, Traefik), make sure to:
- Forward WebSocket connections for HLS streaming
- Set appropriate timeout values for long-lived stream connections
- Configure
AUTH_TRUST_HOST=truefor auto-detection (or setHD_HOMEY_PROXY_HOSTexplicitly) - Ensure
HostandX-Forwarded-Hostheaders are forwarded correctly
Network Configuration
HD Homey needs to communicate with:
- HDHomeRun devices on your local network (port 80 for device API)
- Clients accessing the web interface (port 3000 by default)
- Stream viewers for video delivery (same port as web interface)
Configuration Best Practices
- Always use HTTPS in production - Configure your reverse proxy for HTTPS
- Generate strong secrets - Use
openssl rand -base64 32forAUTH_SECRET - Try auto-detection first - Leave
HD_HOMEY_PROXY_HOSTblank for automatic URL detection - Back up your database - Regular backups of the SQLite database prevent data loss
- Use Docker volumes - Persist data outside containers for easy upgrades
- Monitor disk space - Transcoded streams can use significant disk space
Troubleshooting Configuration
Common configuration issues:
- Authentication loops: Check
AUTH_SECRETis set and persistent - Stream URLs broken: Verify auto-detection works or set
HD_HOMEY_PROXY_HOSTexplicitly - Database errors: Ensure
HD_HOMEY_DB_PATHparent directory is writable - Connection issues: Confirm HDHomeRun devices are reachable from HD Homey host
