Role: arrstack¶
Deploys the media stack Docker Compose application and MediaBot to the arrstack VM.
Hosts: arrstack
Tasks¶
Setup¶
| Task | Tag |
|---|---|
Create /opt/mediaserver directory |
arrstack, setup |
Deploy docker-compose.yml from template |
arrstack, compose |
Deploy .env file (mode 0600 — secrets) |
arrstack, compose |
Any change to the compose file or env triggers a stack restart via handler.
MediaBot¶
| Task | Tag |
|---|---|
Create /opt/mediabot directory |
arrstack, mediabot |
| Clone or update mediabot repo from GitHub | arrstack, mediabot |
Only runs when mediabot_repo is defined in host_vars.
Health check¶
| Task | Tag |
|---|---|
| Query Docker for each container status | arrstack, health |
Report any container not showing Up |
arrstack, health |
Health check is non-destructive — read-only. Run it standalone to audit the stack without changing anything:
Monitored containers:
Note
Gluetun (ProtonVPN WireGuard) routes all qBittorrent traffic through VPN. It is included in the media_stack_containers health check list.
Key variables¶
| Variable | Source | Value |
|---|---|---|
docker_compose_dir |
group_vars / host_vars | /opt/mediaserver |
media_stack_containers |
arrstack host_vars | sonarr, radarr, prowlarr, qbittorrent, seerr |
mediabot_dir |
arrstack host_vars | /opt/mediabot |
mediabot_repo |
arrstack host_vars | https://github.com/rampantlemming/mediabot.git |
Templates¶
| Template | Deploys to | Notes |
|---|---|---|
docker-compose.yml.j2 |
/opt/mediaserver/docker-compose.yml |
Full media stack definition |
env.j2 |
/opt/mediaserver/.env |
API keys and secrets from vault (mode 0600) |
Handlers¶
restart media stack— Runsdocker compose up -dindocker_compose_dirwhen compose or env changes
Related¶
- Arrstack service docs
- MediaBot
- docker role — Must run before this role
- nfs role — NFS mount must be active before compose starts