5.1 KiB
5.1 KiB
Media Stack Documentation
Overview
The media stack runs on Nomad and consists of:
| Service | Port | URL | Purpose |
|---|---|---|---|
| Jellyfin | 8096 | r2d2.hobbs.farm | Media streaming |
| Sonarr | 8989 | sonarr.hobbs.farm | TV show management |
| Radarr | 7878 | radarr.hobbs.farm | Movie management |
| SABnzbd | 8082 | sabnzbd.hobbs.farm | Usenet downloads |
| NZBHydra2 | 5076 | hydra.hobbs.farm | Indexer aggregation |
| Jellyseerr | 5055 | requests.hobbs.farm | Media requests |
Architecture
┌─────────────────────────────────────────────────────────────┐
│ hf-pdocker-01 │
├─────────────────────────────────────────────────────────────┤
│ Nomad Job: media-stack │
│ ┌─────────────────────────────────────────────────────────┐│
│ │ Jellyfin ←──────── /data/media ────────→ Sonarr ││
│ │ ↑ ↑ ↓ ││
│ │ │ Radarr ←──────────→ SABnzbd ││
│ │ │ ↑ ↑ ││
│ │ └────────────── NZBHydra2 ←────────────────┘ ││
│ │ ↓ ││
│ │ Jellyseerr (requests) ││
│ └─────────────────────────────────────────────────────────┘│
│ │
│ Storage: │
│ ├── /data/media/tv (TV shows) │
│ ├── /data/media/movies (Movies) │
│ ├── /data/media/downloads (Download staging) │
│ └── /data/config/* (Per-service configs) │
└─────────────────────────────────────────────────────────────┘
Deployment
Deploy the stack
nomad job run nomad-jobs/media-stack.nomad.hcl
Check status
nomad job status media-stack
nomad alloc status <alloc-id>
View logs
nomad alloc logs <alloc-id> jellyfin
nomad alloc logs <alloc-id> sonarr
Stop the stack
nomad job stop media-stack
Storage Layout
Host Volumes (configured in Nomad)
| Volume Name | Host Path | Services |
|---|---|---|
| media | /data/media | Jellyfin, Sonarr, Radarr |
| downloads | /data/media/downloads | Sonarr, Radarr, SABnzbd |
| jellyfin-config | /data/config/jellyfin | Jellyfin |
| sonarr-config | /data/config/sonarr | Sonarr |
| radarr-config | /data/config/radarr | Radarr |
| sabnzbd-config | /data/config/sabnzbd | SABnzbd |
| nzbhydra2-config | /data/config/nzbhydra2 | NZBHydra2 |
| jellyseerr-config | /data/config/jellyseerr | Jellyseerr |
Service Configuration
Sonarr/Radarr Setup
- Add SABnzbd as download client
- Add NZBHydra2 as indexer
- Configure media paths:
- Root folder:
/media/tv(Sonarr) or/media/movies(Radarr) - Download folder:
/downloads
- Root folder:
SABnzbd Setup
- Configure usenet provider credentials
- Set download folder to
/downloads - Create API key for Sonarr/Radarr
NZBHydra2 Setup
- Add indexer credentials
- Create API key for Sonarr/Radarr
Jellyseerr Setup
- Connect to Jellyfin server
- Connect to Sonarr/Radarr
- Configure user permissions
Secrets (Vault)
Secrets are stored in HashiCorp Vault at secret/media-stack/:
secret/media-stack/sabnzbd
- usenet_server
- usenet_username
- usenet_password
- api_key
secret/media-stack/nzbhydra2
- indexer_api_keys
secret/media-stack/sonarr
- api_key
secret/media-stack/radarr
- api_key
Traefik Integration
Services automatically register in Consul with Traefik tags. Traefik discovers services and creates routes based on the configured Host() rules.
Backup
Config directories should be backed up regularly:
tar -czf media-stack-config-$(date +%Y%m%d).tar.gz /data/config/
Troubleshooting
Container won't start
nomad alloc status <alloc-id>
nomad alloc logs -stderr <alloc-id> <task>
Permission issues
Ensure PUID/PGID match the owner of /data:
ls -la /data/
chown -R 1000:1000 /data/
Service discovery issues
Check Consul:
consul catalog services | grep -E 'jellyfin|sonarr|radarr'
Maintained by Pluto 🪐