tutorials/media-manager #1

Merged
aetos merged 14 commits from tutorials/media-manager into main 2025-11-20 17:37:19 +00:00
18 changed files with 2069 additions and 0 deletions
Showing only changes of commit fb65cc8a57 - Show all commits

View File

@@ -0,0 +1,91 @@
# Prerequisites
Before beginning the Media Manager setup, ensure that your system — whether it is a **fully configured and networked Raspberry Pi** or any other **Linux-based OS** — meets the minimum preparation requirements. Although this guide uses a Raspberry Pi as the reference environment, the setup works on almost any Linux host with minimal or no modification.
---
## Recommended System Requirements
* Raspberry Pi 4 / 5 (4GB or 8GB recommended), or any Linux server/VM
* 64-bit OS
* Minimum 32GB storage
* External HDD/SSD for media storage
* Stable network connection (Ethernet recommended)
---
## What Should Already Be Set Up
### 1. Raspberry Pi flashed and booted
Your system should already have:
* Raspberry Pi OS / Ubuntu Server installed
* First boot completed
* System updated:
```bash
sudo apt update && sudo apt upgrade -y
```
### 2. Network configuration
You should have:
* Working network access
* Static IP or DHCP reservation
* SSH enabled (recommended):
```bash
sudo systemctl enable ssh --now
```
### 3. Storage connected and mounted
If using external HDD/SSD:
* Drives physically connected
* File systems recognized
* Drives mounted persistently via `/etc/fstab`, or prepared for mounting in the Setup Mount Points step
### 4. System time and timezone configured
```bash
sudo timedatectl set-timezone Asia/Kolkata
```
### 5. Basic Linux familiarity
You should be comfortable with:
* Navigating directories
* Editing files using nano or vim
* Running commands via SSH
---
## Optional but Recommended
### Enable UFW Firewall
```bash
sudo apt install ufw
sudo ufw enable
sudo ufw allow ssh
```
### Set a hostname
```bash
sudo hostnamectl set-hostname media-manager
```
### Hardware acceleration for Plex (optional)
Raspberry Pi users may enable VAAPI/V4L2 for improved transcoding.
---
## Next Step
Proceed to **[Overview](steps/overview.md)** once the above setup is complete.

View File

@@ -0,0 +1,71 @@
# Media Manager Setup Guide
Welcome to the **Media Manager Tutorial**.
This guide walks you through setting up a complete, automated media workflow using:
- **Docker** (host)
- **Plex Media Server** (host)
- **qBittorrent** (host)
- **ARR Stack** (Radarr, Sonarr, Prowlarr, Bazarr) via **docker-compose**
Whether you're setting up a home media server or a full automated media pipeline, this documentation provides clear, step-by-step instructions from installation to daily usage.
---
## 📚 What You Will Build
By the end of this guide, you will have a fully configured media management system that:
- Automates movie and TV downloads
- Organizes media files into structured libraries
- Streams content through Plex locally or remotely
- Integrates Radarr/Sonarr with qBittorrent
- Automatically searches for new releases
- Repairs metadata and subtitles
- Requires minimal manual intervention once running
---
## 📁 Components Overview
| Component | Installed On | Purpose |
|------------------|--------------|---------|
| **Docker** | Host | Runs containerized media services (ARR stack) |
| **Plex** | Host | Streams your organized movies/TV shows |
| **qBittorrent** | Host | Torrent client for automated downloads |
| **Arr Stack** (Radarr, Sonarr, Prowlarr, Bazarr) | Docker-Compose | Automated search, download, organization, metadata, subtitles |
---
## 🚀 Quick Navigation
Use the links below to jump to any part of the guide:
| Section | Description |
|---------|-------------|
| [Getting Started](getting-started.md) | Requirements, OS, network, prerequisites |
| [Overview](steps/overview.md) | Summary of the installation workflow |
| [Setup Mount Points](steps/setup-mount-points.md) | Create directories for media, downloads, configs |
| [Install Docker](steps/install-docker.md) | Install Docker + docker-compose |
| [Install Plex](steps/install-plex.md) | Install and configure Plex Media Server |
| [Install qBittorrent](steps/install-qbittorrent.md) | Install and configure qBittorrent |
| [Setup Media Manager](steps/setup-media-manager.md) | Deploy Radarr, Sonarr, Prowlarr, Bazarr with docker-compose |
| [Usage Guide](usage.md) | How to use Plex, Arr, automation steps |
| [Troubleshooting](troubleshooting.md) | Common issues and fixes |
---
## 🧭 How to Use This Guide
This tutorial is structured linearly. You should follow the sections in order unless you already have certain components installed.
---
## 💬 Need Help?
Each step includes explanations, commands, and troubleshooting tips.
If you're stuck, refer to the troubleshooting section or review each command carefully.
---
Lets begin with the basics → **[Getting Started](getting-started.md)**

View File

@@ -0,0 +1,65 @@
site_name: Media Manager Tutorial
nav:
- Home: index.md
- Getting Started: getting-started.md
- Installation:
- Overview: steps/overview.md
- Setup Mount Points: steps/setup-mount-points.md
- Install Docker: steps/install-docker.md
- Install Plex: steps/install-plex.md
- Install Qbittorrent: steps/install-qbittorrent.md
- Setup Media Manager: steps/setup-media-manager.md
- Optional Installation:
- Install Samba: steps/install-samba.md
theme:
name: material
features:
# 🔽 Navigation UX
- navigation.expand # Auto-expand sections
- navigation.sections # Group pages visually
- navigation.top # Floating "back to top" button
- toc.integrate # Integrate ToC into sidebar
# 💡 Content & Code
- content.code.annotate # Annotate code blocks
- content.code.copy # Copy button on code blocks
- content.code.select # ✨ Click to select line blocks
- content.code.line_numbers # ✨ Line numbers by default
- content.tabs.link # Linked tabbed content
- content.tooltips # Hover tooltips for terms
- content.action.edit # “Edit this page” link
# 🧭 Search & UX
- search.suggest # Smart search suggestions
- search.highlight # Highlight matches
- search.share # Shareable search URLs
# 🧱 Structure & Polish
- header.autohide # Auto-hide navbar on scroll
- announce.dismiss # Dismissible announcement bar
- footer.social # Social icons in footer
palette:
scheme: slate # Dark mode
primary: blue grey # Main color
accent: teal # Highlight color
icon:
logo: material/database # DB Icon
repo: fontawesome/brands/github
font:
text: Roboto
code: JetBrains Mono
markdown_extensions:
- pymdownx.highlight:
anchor_linenums: true
linenums_style: table
pygments_lang_class: true
use_pygments: true
auto_title: true
- pymdownx.inlinehilite
- pymdownx.snippets
- pymdownx.superfences
extra_css:
- https://unpkg.com/dracula-prism/dist/css/dracula-prism.css

View File

@@ -0,0 +1,4 @@
# Environment variables
TZ=Asia/Kolkata
PUID=1000
PGID=1000

View File

@@ -0,0 +1,192 @@
# Shared storage configuration
x-shared-storage: &shared_data_volume
type: bind
source: /mnt/omnissiah-vault/data/media-manager
target: /data
bind:
create_host_path: true
# Service-specific volume configurations
x-volume-configs:
jellyseerr: &jellyseerr_volumes
- type: bind
source: /mnt/omnissiah-vault/configs/jellyseerr
target: /app/config
bind:
create_host_path: true
prowlarr: &prowlarr_volumes
- type: bind
source: /mnt/omnissiah-vault/configs/prowlarr
target: /config
bind:
create_host_path: true
- <<: *shared_data_volume
sonarr: &sonarr_volumes
- type: bind
source: /mnt/omnissiah-vault/configs/sonarr
target: /config
bind:
create_host_path: true
- <<: *shared_data_volume
radarr: &radarr_volumes
- type: bind
source: /mnt/omnissiah-vault/configs/radarr
target: /config
bind:
create_host_path: true
- <<: *shared_data_volume
bazarr: &bazarr_volumes
- type: bind
source: /mnt/omnissiah-vault/configs/bazarr
target: /config
bind:
create_host_path: true
- <<: *shared_data_volume
services:
jellyseerr:
image: fallenbagel/jellyseerr:latest
container_name: jellyseerr
ports: ["5055:5055"]
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=${TZ}
volumes: *jellyseerr_volumes
networks:
- media-net
extra_hosts:
- "host.docker.internal:host-gateway"
healthcheck:
test: ["CMD", "wget", "-qO-", "http://localhost:5055"]
interval: 1m
retries: 3
restart: unless-stopped
dns:
- 1.1.1.1
- 8.8.8.8
prowlarr:
image: lscr.io/linuxserver/prowlarr:latest
container_name: prowlarr
ports: ["9696:9696"]
volumes: *prowlarr_volumes
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=${TZ}
networks:
- media-net
extra_hosts:
- "host.docker.internal:host-gateway"
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:9696" ]
interval: 1m
retries: 3
restart: unless-stopped
dns:
- 1.1.1.1
- 8.8.8.8
sonarr:
image: lscr.io/linuxserver/sonarr:latest
container_name: sonarr
ports: ["8989:8989"]
volumes: *sonarr_volumes
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=${TZ}
networks:
- media-net
extra_hosts:
- "host.docker.internal:host-gateway"
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:8989" ]
interval: 1m
retries: 3
restart: unless-stopped
dns:
- 1.1.1.1
- 8.8.8.8
radarr:
image: lscr.io/linuxserver/radarr:latest
container_name: radarr
ports: ["7878:7878"]
volumes: *radarr_volumes
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=${TZ}
networks:
- media-net
extra_hosts:
- "host.docker.internal:host-gateway"
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:7878" ]
interval: 1m
retries: 3
restart: unless-stopped
dns:
- 1.1.1.1
- 8.8.8.8
bazarr:
image: lscr.io/linuxserver/bazarr:latest
container_name: bazarr
ports: ["6767:6767"]
volumes: *bazarr_volumes
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=${TZ}
networks:
- media-net
depends_on:
- sonarr
- radarr
extra_hosts:
- "host.docker.internal:host-gateway"
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:6767" ]
interval: 1m
retries: 3
restart: unless-stopped
dns:
- 1.1.1.1
- 8.8.8.8
ombi:
image: lscr.io/linuxserver/ombi:latest
container_name: ombi
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=${TZ}
volumes:
- /mnt/omnissiah-vault/configs/ombi:/config
ports: ["3579:3579"]
networks:
- media-net
extra_hosts:
- "host.docker.internal:host-gateway"
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:3579" ]
interval: 1m
retries: 3
restart: unless-stopped
dns:
- 1.1.1.1
- 8.8.8.8
networks:
media-net:
driver: bridge
labels:
- "com.media-stack.network=main"
- "com.media-stack.description=Primary network for *arr stack communication with IPv6"

View File

@@ -0,0 +1,42 @@
#!/bin/bash
# Update and upgrade system packages
echo "Updating system packages..."
sudo apt-get update
sudo apt-get upgrade -y
# Remove old Docker versions if any
echo "Removing old Docker versions..."
for pkg in docker.io docker-doc docker-compose podman-docker containerd runc; do
sudo apt-get remove -y $pkg
done
# Install prerequisites for Docker Compose
echo "Installing prerequisites for Docker Compose..."
sudo apt-get install -y libffi-dev libssl-dev python3 python3-pip
# Install Docker using the official convenience script
echo "Installing Docker..."
curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
# Add current user to the Docker group
echo "Adding user to docker group..."
sudo usermod -aG docker $USER
# Enable and start Docker service
echo "Enabling and starting Docker service..."
sudo systemctl enable docker
sudo systemctl start docker
# Install Docker Compose
echo "Installing Docker Compose..."
sudo pip3 install docker-compose
# Verify Docker and Docker Compose versions
echo "Docker version:"
docker --version
echo "Docker Compose version:"
docker-compose --version
echo "Installation complete. Please reboot your Raspberry Pi."

View File

@@ -0,0 +1,49 @@
#!/bin/bash
# Define your custom Plex config directory
CUSTOM_PLEX_CONFIG="/mnt/machine-spirit/configs/plex"
# Update and upgrade system packages
echo "Updating system packages..."
sudo apt update
sudo apt full-upgrade -y
# Install prerequisites
echo "Installing prerequisites..."
sudo apt install -y apt-transport-https curl
# Add Plex official repository GPG key and repo
echo "Adding Plex repository..."
curl https://downloads.plex.tv/plex-keys/PlexSign.key | gpg --dearmor | sudo tee /usr/share/keyrings/plex-archive-keyring.gpg > /dev/null
echo "deb [signed-by=/usr/share/keyrings/plex-archive-keyring.gpg] https://downloads.plex.tv/repo/deb public main" | sudo tee /etc/apt/sources.list.d/plexmediaserver.list
# Update package lists with Plex repo
sudo apt update
# Install Plex Media Server
echo "Installing Plex Media Server..."
sudo apt install -y plexmediaserver
# Stop Plex service before moving config
sudo systemctl stop plexmediaserver
# Move current Plex config to custom location
echo "Moving Plex config to custom directory..."
sudo rsync -av /var/lib/plexmediaserver/ "$CUSTOM_PLEX_CONFIG"/
# Backup and remove existing config directory and create symlink
echo "Setting up symlink from default location to custom config path..."
sudo mv /var/lib/plexmediaserver /var/lib/plexmediaserver.bak
sudo ln -s "$CUSTOM_PLEX_CONFIG" /var/lib/plexmediaserver
# Set correct permissions
echo "Setting permissions for Plex user on custom directory..."
sudo chown -R plex:plex "$CUSTOM_PLEX_CONFIG"
# Start Plex service
sudo systemctl start plexmediaserver
sudo systemctl enable plexmediaserver
echo "Plex Media Server installation complete."
echo "Access the Plex Web UI at http://<your_pi_ip>:32400/web"

View File

@@ -0,0 +1,44 @@
#!/bin/bash
# Update and upgrade system packages
echo "Updating system packages..."
sudo apt update
sudo apt full-upgrade -y
# Install qbittorrent-nox (headless version)
echo "Installing qBittorrent-nox..."
sudo apt install -y qbittorrent-nox
# Create a system user for qBittorrent (optional but recommended)
echo "Creating qBittorrent user..."
sudo useradd -r -m qbt
# Add your normal user (pi) to the qbt group to access downloaded files
sudo usermod -a -G qbt $USER
# Create systemd service file for qBittorrent
echo "Creating systemd service file..."
sudo tee /etc/systemd/system/qbittorrent-nox.service > /dev/null <<EOF
[Unit]
Description=qBittorrent Command Line Client
After=network.target
[Service]
User=$USER
ExecStart=/usr/bin/qbittorrent-nox
Restart=always
[Install]
WantedBy=multi-user.target
EOF
# Reload systemd, enable and start qBittorrent service
echo "Enabling and starting qBittorrent service..."
sudo systemctl daemon-reload
sudo systemctl enable qbittorrent-nox
sudo systemctl start qbittorrent-nox
echo "qBittorrent installation and service setup complete."
echo "Access the Web UI at http://<your_pi_ip>:8080"
echo "Default credentials: username: admin, password: adminadmin"
echo "It's highly recommended to change the default login credentials in the Web UI."

View File

@@ -0,0 +1,99 @@
#!/bin/bash
set -e
# =====================================================================
# ✠ In the Name of the Omnissiah ✠
# Rite of Network Sanctification
# This script forges SMB daemons to guard the sacred data vaults.
# Let no heresy dwell within these parameters.
# =====================================================================
# === CONFIGURATION SIGILS ===
USER="aetos" # Bearer of the Emperor's Sigil
SHARES=(
"/mnt/omnissiah-vault:Omnissiah-Vault" # 7.3TB Holy Vault of Media Relics
"/mnt/machine-spirit:Machine-Spirit" # 931GB Machine Spirit for DBs
)
# === INSTALLATION OF HOLY DAEMONS ===
echo "[*] Installing Samba daemons — awaken smbd & nmbd..."
if command -v apt >/dev/null 2>&1; then
sudo apt update
sudo apt install -y samba
elif command -v dnf >/dev/null 2>&1; then
sudo dnf install -y samba
else
echo "Unsupported package manager. Manual rites required."
exit 1
fi
# === CONSECRATION OF STORAGE SHRINES ===
echo "[*] Consecrating vault directories for Emperors work..."
for entry in "${SHARES[@]}"; do
DIR="${entry%%:*}"
sudo mkdir -p "$DIR"
sudo chown -R "$USER:$USER" "$DIR"
done
# === SMB.CONF SCRIPTURES ===
echo "[*] Backing up smb.conf — preserve the old texts of Mars..."
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf.bak.$(date +%F-%H%M%S)
# Purge traces of past heresies (incorrect configs)
sudo sed -i '/# Omnissiah Vault/,/^\[/d' /etc/samba/smb.conf || true
sudo sed -i '/# Machine Spirit/,/^\[/d' /etc/samba/smb.conf || true
# Inscribe new holy shares into smb.conf
for entry in "${SHARES[@]}"; do
DIR="${entry%%:*}"
NAME="${entry##*:}"
sudo tee -a /etc/samba/smb.conf >/dev/null <<EOF
# ✠ ${NAME} Share ✠
# Machine Spirits bound by the will of the Omnissiah.
[${NAME}]
path = ${DIR}
# Let mortals witness, but not alter without sigil
browseable = yes
# Grant write privileges in Emperors name
read only = no
writable = yes
# HERESY DENIED — no guest trespassers
guest ok = no
# Sigil-bearer ${USER} alone may access
valid users = ${USER}
EOF
done
# === SAMBA PASSWORD RITE ===
echo "[*] Inscribing ${USER} into the Book of smbpasswd..."
sudo smbpasswd -a "$USER"
# === AWAKENING OF DAEMONS ===
echo "[*] Restarting Samba services — let smbd and nmbd chant praises..."
if systemctl list-unit-files | grep -q nmbd.service; then
sudo systemctl restart smbd nmbd
sudo systemctl enable smbd nmbd
else
sudo systemctl restart smbd
sudo systemctl enable smbd
fi
# === VOID SHIELD CONFIG (FIREWALL) ===
if command -v ufw >/dev/null 2>&1; then
sudo ufw allow samba
elif command -v firewall-cmd >/dev/null 2>&1; then
sudo firewall-cmd --permanent --add-service=samba
sudo firewall-cmd --reload
else
echo "[!] No firewall rites detected — proceed with caution, Acolyte."
fi
# === FINAL BLESSING ===
echo "[*] Network sanctification complete!"
echo "Invoke thus from clients:"
echo " smb://<server-ip>/Omnissiah-Vault"
echo " smb://<server-ip>/Machine-Spirit"
echo
echo "✠ May the Emperor and the Omnissiah guard these shares. ✠"

View File

@@ -0,0 +1,128 @@
#!/bin/bash
# Sacred EXT4 Drive Mounting Ritual for the Raspberry Pi Shrine
# May the Omnissiah bless this automaton script
# For the Emperor and the Machine God!
echo "=========================================="
echo " SACRED DRIVE MOUNTING RITUAL INITIATED "
echo " In the name of the Omnissiah we bind "
echo " the Machine Spirits to our will "
echo "=========================================="
echo
# Check if running as root
if [ "$EUID" -ne 0 ]; then
echo "ERROR: This sacred ritual requires root privileges!"
echo "Execute with: sudo bash bind-machine-spirits.sh"
exit 1
fi
echo "🔱 Phase 1: Invoking the Machine Spirit's blessing..."
sleep 1
echo "🛠️ Phase 2: Creating sacred mount point..."
# Mount path
MOUNT_PATH="/mnt/omnissiah-vault"
mkdir -p "$MOUNT_PATH"
# User for directory ownership
AETOS_UID=$(id -u aetos)
AETOS_GID=$(id -g aetos)
chown $AETOS_UID:$AETOS_GID "$MOUNT_PATH"
echo "✅ Sacred directory created:"
echo " 🗂️ $MOUNT_PATH"
echo
echo "💾 Phase 3: Backing up the sacred fstab codex..."
BACKUP_PATH="/etc/fstab.backup.$(date +%Y%m%d_%H%M%S)"
cp /etc/fstab "$BACKUP_PATH"
echo "✅ Backup created: $BACKUP_PATH"
echo
echo "📜 Phase 4: Inscribing the binding runes into fstab..."
# EXT4 UUID (CHANGE THIS!)
VAULT_UUID="REPLACE_WITH_EXT4_UUID"
echo "🔍 Divine revelation of user identities:"
echo " aetos UID: $AETOS_UID"
echo " aetos GID: $AETOS_GID"
# Check if fstab already contains the binding
if grep -q "omnissiah-vault" /etc/fstab; then
echo "⚠️ WARNING: Sacred binding already found in /etc/fstab!"
echo " Avoiding duplicate entries to prevent corruption..."
else
cat >> /etc/fstab << EOF
# Sacred Drive Binding - Blessed by the Omnissiah
# Omnissiah's Vault - EXT4 Media Storage
UUID=${VAULT_UUID} /mnt/omnissiah-vault ext4 defaults,nofail,x-systemd.automount,x-systemd.device-timeout=30s 0 2
EOF
echo "✅ Sacred EXT4 binding inscribed successfully!"
fi
echo "⚡ Phase 5: Awakening the Machine Spirit..."
echo "🔄 Reloading systemd daemon..."
systemctl daemon-reload
# Test mount
if mount -a; then
echo "✅ The Machine Spirit of Omnissiah's Vault has awakened!"
else
echo "❌ ERROR: The Machine Spirit refuses binding!"
echo " Consult the sacred logs for heretical anomalies..."
exit 1
fi
echo
echo "🔍 Phase 6: Verifying the sacred binding..."
echo "Current mount status:"
df -h | grep -E "omnissiah-vault" || echo " The Vault has not yet manifested in the material realm..."
echo
echo "📁 Phase 7: Blessing the directory structure..."
if mountpoint -q "$MOUNT_PATH"; then
mkdir -p $MOUNT_PATH/{movies,tv-shows,documentaries,archives,media,downloads,configs}
chown -R $AETOS_UID:$AETOS_GID $MOUNT_PATH
echo "✅ Directory structure blessed by the Omnissiah"
else
echo "❌ ERROR: Omnissiah's Vault is not mounted. Structure blessing aborted."
fi
echo
echo "=========================================="
echo " SACRED RITUAL COMPLETED! "
echo "=========================================="
echo "🔱 The Machine Spirit is bound!"
echo "🗂️ Vault Path: $MOUNT_PATH"
echo
echo "The Emperor protects your data!"
echo "May your storage serve the Imperium well!"
echo "=========================================="
echo
echo "🔧 Final Systems Check:"
echo "Mounted filesystems:"
mount | grep "omnissiah-vault" | sed 's/^/ /'
echo
echo "Storage capacity report:"
df -h | grep "omnissiah-vault" | sed 's/^/ /'
echo
echo "Directory permissions:"
ls -la /mnt/ | grep "omnissiah-vault" | sed 's/^/ /'
echo
echo "🎉 Ritual complete! Reboot to test automatic mounting."
echo " To verify: sudo reboot && df -h"

View File

@@ -0,0 +1,136 @@
#!/bin/bash
# Sacred Drive Mounting Ritual for the Raspberry Pi Shrine
# May the Omnissiah bless this automaton script
# For the Emperor and the Machine God!
echo "=========================================="
echo " SACRED DRIVE MOUNTING RITUAL INITIATED "
echo " In the name of the Omnissiah we bind "
echo " the Machine Spirits to our will "
echo "=========================================="
echo
# Check if running as root
if [ "$EUID" -ne 0 ]; then
echo "ERROR: This sacred ritual requires root privileges!"
echo "Execute with: sudo bash bind-machine-spirits.sh"
exit 1
fi
echo "🔱 Phase 1: Invoking the Machine Spirit's blessing..."
sleep 1
# Install NTFS support if missing
echo "📦 Ensuring NTFS-3G drivers are blessed by the Omnissiah..."
apt update -qq
apt install -y ntfs-3g
echo "🛠️ Phase 2: Creating sacred mount point..."
# Create mount directory
mkdir -p /mnt/omnissiah-vault
# Get dynamic user ID/GID for the aetos user
AETOS_UID=$(id -u aetos)
AETOS_GID=$(id -g aetos)
# Assign ownership
chown $AETOS_UID:$AETOS_GID /mnt/omnissiah-vault
echo "✅ Sacred directory created:"
echo " 🗂️ /mnt/omnissiah-vault (the great data hoard)"
echo
echo "💾 Phase 3: Backing up the sacred fstab codex..."
# Backup fstab
BACKUP_PATH="/etc/fstab.backup.$(date +%Y%m%d_%H%M%S)"
cp /etc/fstab "$BACKUP_PATH"
echo "✅ Backup created: $BACKUP_PATH"
echo
echo "📜 Phase 4: Inscribing the binding runes into fstab..."
echo "🔍 Divine revelation of user identities:"
echo " aetos UID: $AETOS_UID"
echo " aetos GID: $AETOS_GID"
# Your UUID goes here — update if needed
VAULT_UUID="C678E33A78E3283F"
# Check existing entries
if grep -q "omnissiah-vault" /etc/fstab; then
echo "⚠️ WARNING: Sacred bindings already detected in fstab!"
echo " Skipping fstab modification to prevent corruption..."
else
cat >> /etc/fstab << EOF
# Sacred Drive Binding - Blessed by the Omnissiah
# Omnissiah's Vault - Mass Storage for Movies & Media
UUID=${VAULT_UUID} /mnt/omnissiah-vault ntfs-3g defaults,nofail,uid=${AETOS_UID},gid=${AETOS_GID},umask=022,x-systemd.automount,x-systemd.device-timeout=30s 0 0
EOF
echo "✅ Sacred binding inscribed successfully!"
fi
echo "⚡ Phase 5: Awakening the Machine Spirit..."
# Reload systemd to acknowledge the sacred changes
echo "🔄 Reloading systemd daemon..."
systemctl daemon-reload
# Test mount
if mount -a; then
echo "✅ The Machine Spirit of Omnissiah's Vault has awakened!"
else
echo "❌ ERROR: The Machine Spirit resists binding!"
echo " Consult the sacred logs for heretical errors..."
exit 1
fi
echo
echo "🔍 Phase 6: Verifying the sacred binding..."
echo "Current mount status:"
df -h | grep -E "omnissiah-vault" || echo " The Vault has not yet manifested in the material realm..."
echo
echo "📁 Phase 7: Blessing the directory structure..."
if mountpoint -q /mnt/omnissiah-vault; then
mkdir -p /mnt/omnissiah-vault/{movies,tv-shows,documentaries,archives,media,downloads,configs}
chown -R $AETOS_UID:$AETOS_GID /mnt/omnissiah-vault
echo "✅ Omnissiah's Vault directory structure blessed"
else
echo "❌ ERROR: Omnissiah's Vault is not mounted. Cannot bless structure."
fi
echo
echo "=========================================="
echo " SACRED RITUAL COMPLETED! "
echo "=========================================="
echo "🔱 The Machine Spirit is bound!"
echo "🗂️ Vault Path: /mnt/omnissiah-vault"
echo
echo "The Emperor protects your data!"
echo "May your storage serve the Imperium well!"
echo "=========================================="
echo
echo "🔧 Final Systems Check:"
echo "Mounted filesystems:"
mount | grep "omnissiah-vault" | sed 's/^/ /'
echo
echo "Storage capacity report:"
df -h | grep "omnissiah-vault" | sed 's/^/ /'
echo
echo "Directory permissions:"
ls -la /mnt/ | grep "omnissiah-vault" | sed 's/^/ /'
echo
echo "🎉 Ritual complete! Reboot to test automatic mounting."
echo " To verify: sudo reboot && df -h"

View File

@@ -0,0 +1,172 @@
# Installing Docker — What It Is, How It Works, and Why We Use It
Before installing Docker, its important to understand **what Docker actually does**, **how it fits into our media management setup**, and **why we run only the ARR stack inside Docker** while keeping **qBittorrent and Plex on the host system**.
This page will walk you through all of that in simple, practical terms.
---
# 🐳 What Is Docker?
Docker is a **containerization platform**.
That means:
### Docker lets you run applications in small, isolated environments called **containers**.
A container:
- has its own filesystem
- has its own dependencies
- has its own libraries
- cannot interfere with your main system
- can be destroyed and recreated easily
Think of it like:
> **A lightweight, specialized mini-computer for one application.**
This makes apps more predictable, easier to upgrade, and easier to manage.
---
# 🔧 Why Use Docker?
### ✔ Avoid dependency conflicts
Containers ship the libraries the app needs, so you dont pollute your main OS.
### ✔ Easy to update
Updating Radarr/Sonarr/Prowlarr becomes:
```
docker compose pull
docker compose up -d
```
### ✔ Easy to back up
ARR services store their config in a small folder you can snapshot.
### ✔ Perfect for things that change often
Indexers break, Prowlarr updates, Radarr adds features — Docker makes it painless.
---
# 🚫 Why Not Put Everything in Docker?
You *can* put everything in Docker, but in a real-world Raspberry Pi / home-server environment, some apps **behave badly** or **have limitations** inside containers.
Below is the reasoning for each major component.
---
# ❌ Why qBittorrent Is NOT in Docker
### qBittorrent needs:
- fine-grained permission control
- direct disk access
- stable file paths
- high-speed I/O for torrent hashing
- ability to handle sudden restarts and disk states
Inside Docker, qBit often has problems:
| Problem | Why It Happens |
|--------|----------------|
| Slow hashing | Dockers overlay filesystem adds overhead |
| Permission issues | Containers struggle with mixed UID/GID + bind mounts |
| Inconsistent paths | qBit expects real Linux paths for completed downloads |
| Harder integration | Radarr/Sonarr sometimes misread container-mapped paths |
### 🧠 Therefore:
**qBittorrent on the host is cleaner, faster, and more stable.**
---
# ❌ Why Plex Is NOT in Docker
This is even more important.
### Plex inside Docker struggles with:
| Feature | Issue in Docker |
|--------|-----------------|
| **Hardware transcoding (VAAPI/V4L2/QuickSync)** | Often broken or requires special setup |
| **Direct I/O from large libraries** | Docker overlay adds slowdowns |
| **Automatic network discovery** | Plex uses multicast/IGMP which Docker isolates |
| **Large metadata directories** | Docker containers dont like millions of tiny files |
Plex has a massive, constantly evolving I/O profile and **performs best on bare metal** (host).
### 🧠 Therefore:
**Install Plex directly on the host for speed, compatibility, and transcoding support.**
---
# 🟩 Why the ARR Stack *Is* in Docker
Radarr, Sonarr, and Prowlarr:
- are lightweight
- use clean, simple paths
- store configuration in manageable folders
- benefit from frequent updates
- rarely need hardware access
- behave very predictably in containers
Theyre practically **designed to live inside Docker**.
### ✔ Consistent paths
As long as `/mnt/omnissiah-vault` is mounted, containers have zero issues.
### ✔ Easy migrations
Moving to a new server is as simple as:
```
copy configs → run docker-compose → done
```
### ✔ Better isolation
If Radarr breaks from an update, it wont affect Plex or qBit.
---
# 🧱 Summary — The Architecture Philosophy
| Component | Host or Docker? | Reason |
|----------|------------------|---------|
| **Docker Engine** | Host | Foundation layer |
| **ARR Stack (Radarr / Sonarr / Prowlarr / Bazarr)** | Docker | Best candidates for containers |
| **qBittorrent** | Host | Needs stable I/O + real filesystem access |
| **Plex** | Host | Needs hardware transcoding + network discovery |
This hybrid approach gives us the **best combination of performance, stability, and maintainability**.
---
# 🧰 Installing Docker (Raspberry Pi / Linux)
Here is the installation script referenced in the flow:
### 📥 Download Script
👉 **[install-docker.sh](../scripts/shell/install-docker.sh)**
### 🖥️ What the script does
- updates the system
- removes conflicting old packages
- installs Docker using the official convenience script
- installs Docker Compose
- adds your user to the docker group
- enables and starts the Docker service
- verifies installation
After running it:
```bash
sudo reboot
```
Your system will be ready to run containerized ARR services.
# 🚀 Next Step: Configure Plex (Host Installation)
Once Docker is installed, we move forward with:
👉 Install Plex (steps/install-plex.md)
This ensures the server is ready to serve media once the ARR stack begins populating it.

View File

@@ -0,0 +1,124 @@
# Installing Plex Media Server
Plex is the heart of your media ecosystem. It scans your library, fetches metadata, organizes everything neatly, and makes your movies and shows available to stream from anywhere. Installing Plex is straightforward, but **where you store its configuration and metadata** is extremely important.
This guide explains:
* What Plex is and how it works
* Why it should *not* run inside Docker in this setup
* Why its configuration directory must be placed on your external HDD
* What gets stored there and how large it can grow
* The installation script used to set everything up
---
# 🎬 What Is Plex?
Plex Media Server is an application that:
* Indexes your media library
* Fetches rich metadata (posters, backgrounds, cast info, themes)
* Streams your content to TVs, phones, tablets, and browsers
* Transcodes media when needed
* Manages user accounts, watch history, and recommendations
Plex is extremely powerful — but with that power comes heavy disk usage.
---
# 🧱 Why Plex Runs *Outside* Docker
Although Docker is fantastic for the ARR stack, Plex is more demanding and behaves better on the **host system**.
Running Plex in Docker often introduces problems:
| Issue | Why It Happens in Docker |
| ------------------------------------ | -------------------------------------------------------- |
| **Hardware transcoding failures** | Containerization interferes with VAAPI/V4L2/QuickSync |
| **Slow scanning of large libraries** | Docker's overlay filesystem slows metadata I/O |
| **Network discovery issues** | Plex requires multicast/IGMP, blocked by Docker networks |
| **Large metadata directory** | Containers struggle with millions of tiny files |
Real-world experience proves Plex performs best when installed directly on the OS.
---
# 🗃️ Why Move Plex Metadata to an External HDD?
Plex stores a massive amount of metadata — often **tens or hundreds of gigabytes** depending on library size.
Heres what Plex stores inside its config directory:
* Posters & artwork
* Backdrops
* Theme music
* Subtitles
* Optimization cache
* Transcoding cache
* Databases for:
* Libraries
* Watch history
* Video analysis
* Intro detection
These files grow quickly.
## 📌 Example Metadata Sizes
* Small library (500 files): **510 GB**
* Medium library (2,000 files): **2050 GB**
* Large library (10,000+ files): **100 GB+**
If you keep this in `/var/lib/plexmediaserver` on the SD card or system SSD:
* The OS disk will fill up
* SD cards will wear out quickly
* Plex performance will suffer severely
### ✔ Placing metadata on your external HDD solves everything
* Massive storage availability
* Higher endurance than SD cards
* Faster scanning and caching
* No risk of filling the root filesystem
This is why we relocate Plex config to:
```
/mnt/omnissiah-vault/configs/plex
```
---
# ⚙️ Installation Script
Below is the installation script used for this tutorial. It:
* Installs Plex Media Server from the official repository
* Stops the service
* Moves its entire metadata/config directory to your mounted HDD
* Creates a symlink so Plex still sees the expected path
* Ensures correct ownership for the `plex` user
* Restarts and enables the service
* 📥 Download Script
👉 **[install-docker.sh](../scripts/shell/install-plex.sh)**
---
# 🚀 After Installation
Once Plex is installed and its metadata moved to your external drive, you can:
* Open the Web UI
* Sign in with your Plex account
* Add your libraries from `/mnt/omnissiah-vault/media`
* Run a full scan
Everything moving forward — including posters, metadata, intro detection, and caching — will stay safely on the external HDD.
---
# ➡️ Next Step
Proceed to **Install qBittorrent** to complete the host-based components.

View File

@@ -0,0 +1,134 @@
# Installing qBittorrent (Host Installation)
qBittorrent is the download engine of your media automation setup. It handles all torrent activity triggered by Radarr, Sonarr, and Prowlarr. Installing it on the **host system** (not Docker) ensures optimal speed, stable paths, and maximum compatibility.
This guide explains:
* What qBittorrent does in the media pipeline
* Why it should *not* run inside Docker in a real-world Pi/home server setup
* Why its configuration does **not** need to be moved to your external drive
* The installation script used to install and run qBittorrent as a systemd service
---
# 🌀 What Is qBittorrent?
qBittorrent is an opensource torrent client with:
* A lightweight Web UI
* Fast download engine
* Built-in category and tagging support
* Excellent integration with Radarr & Sonarr
* Very low resource usage
It acts as the **download worker** for the entire Media Manager.
When Radarr/Sonarr find a new movie or episode, they send the torrent to qBittorrent. When the download completes, ARR handles renaming and moving the file.
---
# ❌ Why qBittorrent Should NOT Run in Docker
Although qBittorrent *can* run in Docker, it performs **significantly worse** and causes practical issues when used on low-power servers like Raspberry Pi.
Heres why.
## 🐌 1. Docker slows down torrent hashing
qBit must:
* Hash large files
* Verify blocks
* Manage partial pieces
Docker overlays add filesystem overhead → hashing becomes slower → CPU usage increases.
## 🔐 2. Permissions become messy
Inside Docker:
* Download paths are bind-mounted
* UID/GID mapping becomes inconsistent
* Sonarr/Radarr sometimes cannot see or import completed downloads
On the host:
* Files are native
* Permissions are predictable
* ARR integration is flawless
## 📁 3. Real file paths are required for stability
qBit expects stable, real Linux paths like:
```
/mnt/omnissiah-vault/downloads
```
Containers often abstract or rewrite these, confusing ARR.
## 🚀 4. Performance is dramatically better on the host
Download speed, disk writes, and hashing are all faster without Docker.
### ✔ Therefore:
**qBittorrent belongs on the host system for maximum stability and speed.**
---
# 📦 Why qBittorrent Config Does NOT Go on the External HDD
Unlike Plex—which can generate **tens of gigabytes** of metadata—qBittorrent stores only:
* a few small configuration files
* a few `.fastresume` entries
* a small database of torrents
Typical qBit config directory size:
* 220 MB
It does **not** grow with your media library.
### ✔ Keeping qBit on the internal OS disk is safe and recommended.
---
# ⚙️ Installation Script (Systemd Service)
The script below installs qBittorrentnox and configures it to run as a background service.
* 📥 Download Script
👉 **[install-docker.sh](../scripts/shell/install-qbittorrent.sh)**
---
# 🚀 After Installation
Visit:
```
http://<your_pi_ip>:8080
```
Default credentials:
```
username: admin
password: adminadmin
```
You *must* change the password on first login.
Next steps:
* Configure download paths
* Add categories (`movies`, `tv`, etc.)
* Disable torrenting features you dont need
ARR integration happens after the Docker portion is set up.
---
# ➡️ Next Step
Proceed to the **ARR Stack setup (Docker Compose)** to handle automation.

View File

@@ -0,0 +1,164 @@
# Optional: Installing Samba for Windows Network Access
Samba is **optional** in this Media Manager setup, but highly recommended if:
* You use **Windows** and want to browse your media files easily
* You want to manually adjust or inspect downloaded files
* You want to drag-and-drop subtitles, rename files, or fix issues directly
* You want the flexibility of mounting your media as a network drive
If you only ever access files through Plex, ARR apps, or the Linux shell, then Samba is **not required**.
---
# 🧩 Why Samba Might Be Needed
Although Radarr, Sonarr, and Bazarr automate nearly everything, there are situations where **manual file access** is useful:
* Fixing incorrectly tagged files
* Manual subtitle adjustments
* Deleting or replacing corrupted media
* Organizing large folders
* Backing up media manually
On **Linux or macOS**, this can be done easily over SSH.
On **Windows**, the easiest way is via **Samba (SMB)** network shares.
---
# 💠 What Samba Does
Samba exposes directories on your Raspberry Pi/Linux server as Windows-compatible network drives.
It allows you to access:
```
/mnt/omnissiah-vault
```
from Windows like:
```
Z:\ → Omnissiah-Vault
```
This behaves like a native Windows drive:
* You can open files
* Copy folders
* Delete/rename items
* Perform maintenance tasks
---
# 📦 Installation Script (Optional)
If you want Samba on your server, use the following script:
👉 **see script:** `scripts/install-samba.sh`
This script:
* Installs Samba
* Shares your mounted directories
* Secures access to your user only (no guest access)
* Creates Samba credentials
* Enables the smbd/nmbd daemons
---
# 🖥️ Windows Setup — Mapping the Network Drive
Once Samba is active, you can connect from Windows.
### 1. Open File Explorer
Press:
```
Win + E
```
### 2. Click **This PC**
### 3. Click **Map network drive** in the top ribbon
(If hidden, click the three-dot menu.)
### 4. Choose a drive letter
Example:
```
Z:
```
### 5. In the folder field, enter your Samba share
```
\\<server-ip>\Omnissiah-Vault
```
Example:
```
\\192.168.1.50\Omnissiah-Vault
```
### 6. Check **Reconnect at sign-in**
So Windows auto-remounts the drive.
### 7. Check **Connect using different credentials**
Enter the username and password created during Samba setup:
```
Username: aetos
Password: <your-samba-password>
```
Click **Finish**.
You should now see the drive appear in Explorer like a normal disk.
---
# 🧰 You Can Also Map via Command Line
Open PowerShell and run:
```
net use Z: \\<server-ip>\Omnissiah-Vault /user:aetos
```
---
# 🔐 Security Notes
* Samba exposes your filesystem over the network → keep your password strong.
* Never enable `guest ok = yes` unless you want an open share.
* Use UFW or firewall-cmd to restrict access if needed.
---
# 📝 Summary
Samba is optional but extremely convenient, especially for Windows users.
Use it if:
* You manage files manually
* You want drag-and-drop access to media
* You want Windows Explorer to treat the server like a normal drive
Skip it if:
* Everything happens via automation
* You only use Plex and ARR
* You manage your server exclusively from Linux/Mac
---
Proceed to the next step when ready.

View File

@@ -0,0 +1,130 @@
# Overview
This page tells the story of what will happen during the Media Manager setup: a clear, step-by-step timeline of actions, goals, and outcomes. Think of it as the "mission plan" — what we do, why we do it, and what success looks like at each stage.
---
## The goal
We'll transform a single Linux host (example: a Raspberry Pi) into a dependable, mostly-automated media management server that:
* Downloads TV shows and movies automatically via qBittorrent
* Uses the ARR stack (Radarr, Sonarr, Prowlarr, Bazarr) to find and manage media
* Organizes and moves completed downloads into a structured media library
* Serves your media using Plex Media Server
* Runs ARR services in Docker for portability and ease of upgrades
---
## High-level architecture
* **Host OS**: Linux (Raspberry Pi OS / Ubuntu Server)
* **Host services**: Docker (engine) + Plex + qBittorrent (native host installs)
* **Containerized services** (docker-compose): Radarr, Sonarr, Prowlarr, Bazarr, and any auxiliary containers (e.g., file indexers, notifications)
* **Storage layout**: downloaded files land in `/mnt/downloads`; completed and organized media live in `/mnt/media`; service configurations in `/mnt/config`
---
## Step-by-step timeline (what will happen)
Each step below explains the action, the reason, and the expected result.
### 1) Validate base system
**Action:** Confirm OS, update packages, set hostname, timezone, and networking.
**Why:** Ensures reproducible behavior, correct timestamps, and easier network access.
**Result:** A stable host with SSH enabled and a predictable IP/hostname.
---
### 2) Prepare and mount storage
**Action:** Attach external drives (HDD/SSD or network share), create filesystems if needed, and mount them persistently (e.g., `/etc/fstab`). Create top-level folders:
```
/mnt/media
/mnt/downloads
/mnt/config
```
**Why:** Separates volatile system disk from large media storage and config data; makes backups and maintenance easier.
**Result:** Durable storage locations that all services will reference.
---
### 3) Install Docker on the host
**Action:** Install Docker Engine and docker-compose (or use `docker compose` plugin).
**Why:** ARR services are containerized for isolation, portability, and simplified updates.
**Result:** Host ready to run docker-compose stacks.
---
### 4) Install Plex on the host
**Action:** Install Plex Media Server as a host service (native install or package). Configure initial library paths and remote access as needed.
**Why:** Plex performs heavy I/O and benefits from being on the host where hardware acceleration and direct disk access are easier to configure.
**Result:** Plex server visible on the network and ready to index `/mnt/media`.
---
### 5) Install qBittorrent on the host
**Action:** Install and configure qBittorrent (preferably `qbittorrent-nox` for headless use). Set download paths to `/mnt/downloads`. Configure a web UI and credentials.
**Why:** Torrent client handles downloads; being on the host simplifies mounting and permissions.
**Result:** qBittorrent runs as a service, accepting search/download requests from ARR services.
---
### 6) Deploy ARR Stack via docker-compose
**Action:** Create a `docker-compose.yml` to run Radarr, Sonarr, Prowlarr, Bazarr (and optional services like bazarr, jackett if needed). Mount config and media/downloads into containers.
**Why:** Containers give predictable runtime environments and make upgrades simple.
**Result:** ARR services running and reachable on defined ports (e.g., `:7878` for Radarr, `:8989` for Sonarr).
---
### 7) Integrate ARR with qBittorrent and Plex
**Action:** In Radarr/Sonarr, add qBittorrent as the download client and Plex for library updates. Configure Prowlarr as the indexer aggregator and link it to Sonarr/Radarr.
**Why:** This creates an automated chain: indexers → ARR → torrent client → completed move → Plex scan.
**Result:** A working automation pipeline where new media requests result in downloaded, organized, and indexed media.
---
### 8) Configure media organization and quality profiles
**Action:** Create library structures (Movies, TV), set naming formats, define quality profiles and root folders in Radarr and Sonarr.
**Why:** Ensures consistent file naming, reduces duplicates, and keeps libraries tidy for Plex.
**Result:** Downloads are renamed and moved automatically into `/mnt/media/Movies` and `/mnt/media/TV`.
---
### 9) Verify and test end-to-end flow
**Action:** Manually request a test show or movie in Sonarr/Radarr, verify it appears in qBittorrent, completes, is moved, and shows up in Plex.
**Why:** Confirms the full automation loop works and surfaces permission or path issues.
**Result:** Confirmed working pipeline.
---
### 10) Backup, maintenance, and monitoring
**Action:** Implement config backups (snapshot `/mnt/config`), schedule regular system updates, and optionally add monitoring (Prometheus/Grafana or simple scripts).
**Why:** Protects against data loss and keeps services healthy.
**Result:** Resilient installation with a recovery plan.
---
## Success Criteria — How youll know its working
* You can add a movie/show to Radarr/Sonarr and see it downloaded automatically.
* Downloaded files are renamed and relocated to `/mnt/media`.
* Plex detects new content and makes it available for streaming.
* Services restart correctly after a reboot and maintain configuration.
---
## Next steps
Proceed to the **Setup Mount Points** step to prepare storage paths and permissions: `steps/setup-mount-points.md`.

View File

@@ -0,0 +1,268 @@
# ARR Stack Overview and Service Architecture
This section explains all the applications included in your Media Manager stack, what each one does, how they interact with each other, and how the storage mount points are shared across services.
The stack is deployed using a **Docker Compose file**. Instead of pasting the compose inline here, it is referenced directly:
👉 **See the Docker Compose configuration:** `docker-compose.yml`
---
# 🌐 The ARR Ecosystem — What Each App Does
Your media automation pipeline consists of several specialized services. Each one has a dedicated role, and together they form a complete endtoend system.
Below is a clear breakdown.
---
## 🧭 Prowlarr — The Indexer Aggregator
Prowlarr acts as the central hub for all indexers (public, private, torrent, NZB).
**Responsibilities:**
* Connects to multiple indexers
* Provides unified indexer results to Radarr & Sonarr
* Manages API keys, categories, indexer syncing
**Why its important:**
Without Prowlarr, you would configure indexers separately in each application — a massive duplication of work.
**How it talks to others:**
* Sends torrent results → Radarr/Sonarr
* Receives indexer categories from them
---
## 🎬 Radarr — Automated Movie Management
Radarr handles **movie** automation.
**Responsibilities:**
* Monitor movie requests
* Fetch releases from indexers via Prowlarr
* Trigger downloads via qBittorrent
* Rename, sort, and move completed files into the Movies directory
* Update Plex libraries
**How it talks to others:**
* Index results from Prowlarr
* Sends download requests to qBittorrent
* Notifies Plex to refresh libraries
* Provides subtitles to Bazarr (optional)
---
## 📺 Sonarr — Automated TV Show Management
Sonarr is the TV equivalent of Radarr.
**Responsibilities:**
* Track TV episodes (past and future)
* Upgrade quality automatically
* Send downloads to qBittorrent
* Rename and organize episodes
**How it talks to others:**
* Index results from Prowlarr
* Send downloads to qBittorrent
* Sync subtitle requests with Bazarr
---
## 💬 Bazarr — Subtitle Management Service
Bazarr automatically finds and downloads subtitles.
**Responsibilities:**
* Sync with Radarr and Sonarr
* Fetch subtitles in desired languages
* Store subtitles next to their respective media files
**How it talks to others:**
* Reads Radarr/Sonarr libraries
* Writes subtitle files directly inside `/data/media/...`
---
## 🎟️ Jellyseerr — Request Management Portal
Jellyseerr is the user-facing request dashboard.
**Responsibilities:**
* Users request movies or shows
* Requests are forwarded automatically to Radarr/Sonarr
* Designed for multi-user setups
**How it talks to others:**
* Communicates with Radarr/Sonarr via API
* Shows availability status using Plex integration
---
## 📨 Ombi — Alternative Request Management
Ombi is similar to Jellyseerr, with some different UI and features.
**Responsibilities:**
* Allows users to request media
* Integrates with Radarr and Sonarr
* Sends notifications
Some prefer Jellyseerr, others prefer Ombi — you can run both.
---
# 🧱 How These Services Are Connected
### Central Flow Diagram (conceptual)
```
Jellyseerr/Ombi → Radarr/Sonarr ← Prowlarr
qBittorrent (host)
Organized media library
Plex
Clients
```
### Key Points:
* **Prowlarr provides indexer data** to both Radarr and Sonarr
* **Radarr/Sonarr send download requests** to qBittorrent (host)
* **qBittorrent stores downloads** into the shared mounted folders
* **Radarr/Sonarr import, rename, and move** completed media into `/data/media/...`
* **Plex sees updated libraries** and refreshes
* **Bazarr fetches subtitles** and writes them next to the media
All Docker apps talk to host apps using:
```
host.docker.internal:host-gateway
```
This ensures containers can reach qBittorrent and Plex.
---
# 🗄️ Volume Mount Strategy
All apps share a **standardized mount point** inside containers:
```
/data
```
Outside the container, this maps to:
```
/mnt/omnissiah-vault/data/media-manager
```
This ensures:
* Radarr, Sonarr, Bazarr all see the **same folder structure**
* No path translation issues between apps
* Clean docker-compose configuration
### Example Inside Containers
```
/data/media/movies
/data/media/tv
/data/downloads
```
---
# 🗂️ Config Directory Mounts
Each service stores its settings inside Docker volumes mapped to persistent directories.
### Radarr
```
/mnt/omnissiah-vault/configs/radarr → /config
```
### Sonarr
```
/mnt/omnissiah-vault/configs/sonarr → /config
```
### Prowlarr
```
/mnt/omnissiah-vault/configs/prowlarr → /config
```
### Bazarr
```
/mnt/omnissiah-vault/configs/bazarr → /config
```
### Jellyseerr
```
/mnt/omnissiah-vault/configs/jellyseerr → /app/config
```
### Ombi
```
/mnt/omnissiah-vault/configs/ombi → /config
```
All containers get persistent configuration that survives updates.
---
# 🔧 Docker Networking
All ARR services join the same Docker network:
```
media-net
```
This provides:
* Internal communication
* Isolated service space
* Avoids exposing containers unintentionally
---
# 🚀 Summary
Your ARR stack consists of:
* **Prowlarr** for indexers
* **Sonarr** for TV
* **Radarr** for movies
* **Bazarr** for subtitles
* **Jellyseerr or Ombi** for request management
They connect using APIs, communicate through a private Docker network, and share a unified `/data` folder that maps to your mounted storage.
This architecture keeps everything predictable, reproducible, and easy to maintain.
---
Next: Proceed to configure each service inside their Web UIs.

View File

@@ -0,0 +1,156 @@
# Understanding Mounting, File Systems, and Choosing Between EXT4 vs NTFS
Before we bind our drives and awaken the Machine Spirits, its important to understand **what mounting is**, **what file systems are**, and **why we choose EXT4 or NTFS** depending on how the drive will be used.
This page explains everything in simple terms so beginners can follow confidently.
---
## 🧩 What Does “Mounting” Mean?
On Linux, storage devices like HDDs, SSDs, or USB drives **do not automatically appear as folders**.
Instead, the operating system must *mount* them — meaning:
### **Mounting = attaching a physical drive to a folder on the filesystem.**
For example:
```
Device: /dev/sda1
Mounted at: /mnt/omnissiah-vault
```
Once mounted:
- The drive becomes accessible through that folder
- Applications can read/write files there
- You can organize media, downloads, and configuration data
If the drive is *not mounted*, nothing can access it—even if Linux sees the hardware.
---
## 📘 Why We Use `/mnt/…`
Linux keeps the system organized using conventions:
| Path | Purpose |
|------|---------|
| `/home` | User home folders |
| `/root` | Root account home |
| `/etc` | System configuration |
| `/mnt` | Drives mounted by the user/admin |
We follow the Linux standard by mounting drives under:
```
/mnt/omnissiah-vault
```
This makes it clear that the drive is external storage, not part of the system root.
---
## 🔧 What Is a File System?
A **file system** determines how data is organized on a drive.
It controls:
- How files are stored
- How permissions work
- How large files can be
- How reliable and fast the storage is
Two major file systems matter for media management:
---
# 🆚 EXT4 vs NTFS — Which Should You Use?
Below is a simple, clear comparison.
| Feature | EXT4 (Linux Native) | NTFS (Windows Native) |
|--------|----------------------|------------------------|
| Best OS support | Linux | Windows |
| Performance on Linux | ⭐⭐⭐⭐ Fast | ⭐ Slow (requires NTFS-3G driver) |
| Supports Linux permissions (chmod, chown) | ✔ Yes | ❌ No (emulated) |
| Good for Plex & ARR stack | ✔ Best choice | ✔ Works but slower |
| Reliability | ⭐⭐⭐⭐⭐ Excellent | ⭐⭐⭐ Good |
| 4K/large drive support | ✔ Yes | ✔ Yes |
| Automatic mounting | Easy | Slightly more complex |
| Ideal use case | Permanent Linux storage | External drive shared with Windows |
### ✔ **Choose EXT4 if the drive stays connected to your Raspberry Pi/Linux system.**
This is the recommended choice for **media servers**, **Plex**, and **qBittorrent** because:
- Its faster
- Uses native permissions
- More stable
- Less CPU overhead
- Easier integration with Docker
### ✔ **Choose NTFS only if the drive must also be used on Windows.**
For example:
- You physically unplug the drive and connect it to a Windows PC
- You want to browse the media on Windows without a network share
---
## 🪟 Accessing an EXT4 Drive on Windows?
EXT4 cannot be read by Windows *natively*.
However, **this is not a problem**, because:
### You will access your media over the network using **Samba (SMB)**.
This means:
- You keep the performance, safety, and permissions of EXT4
- Windows PCs can still browse the media like a shared network drive
We will configure Samba later in an optional section:
👉 *“Accessing Your Media from Windows (Samba Setup)”*
---
## 📥 Choose Your Mounting Ritual
Below are two scripts — pick one based on your file system choice.
### 🟦 EXT4 Mounting Ritual (Recommended)
**Download:**
👉 [bind-machine-spirits-ext4.sh](../scripts/shell/setup-mount-points/ext4.sh)
(Use this if your drive is formatted as EXT4 and stays connected permanently.)
---
### 🟨 NTFS Mounting Ritual (Legacy/Optional)
**Download:**
👉 [bind-machine-spirits-ntfs.sh](../scripts/shell/setup-mount-points/ntfs.sh)
(Use this only if your drive must work on both Linux and Windows without Samba.)
---
## 🧭 What Happens Next?
Once you choose your file system and run the ritual script:
1. Your mount point will be created
2. `/etc/fstab` will be updated for automatic mounting
3. The drive will appear under `/mnt/omnissiah-vault`
4. Subdirectories (movies, tv-shows, downloads, etc.) will be generated
## Next steps
Proceed to the **Setup Mount Points** step to prepare storage paths and permissions: `steps/setup-mount-points.md`.
👉 **Install Docker**
with all your directory paths standardized and ready for the media automation pipeline.
---