Docs pass: update headers and READMEs for all new scripts
Script headers (6 files): - Add OPERATIONAL SAFEGUARDS section to all discovery + emby sync scripts - Add STATE FILES section to all 3 discovery scripts - Add CONFIGURATION section to emby_to_*_sync.sh - Rename USAGE → RUNTIME MODES in emby_to_*_sync.sh (doc standard) - Fix SONARR_DISCOVERY_MONITOR_MODE default doc: "future" → "all" Media/README-Media.md: - Remove "WIP prototype" label; describe all 3 discovery scripts - Add discovery scripts to scripts table and HOW THE SCRIPTS RELATE diagram - Add weekly discovery schedule block to EXECUTION ORDER section - Update intro to mention behavior-driven discovery Media/Manual-Media.md: - Add configuration reference sections for all 3 discovery scripts - Add flag reference sections for all 3 discovery scripts Tools/README-Tools.md: - Add "Library Sync Bootstrap" category and emby_to_*_sync.sh to scripts table - Add emby sync scripts to HOW THE SCRIPTS RELATE diagram Tools/Manual-Tools.md: - Update emby sync notes: search commands now fire immediately after add README.md: - Update Media folder description to include discovery - Update weekly schedule to show discovery scripts - Update README table entry for Media
This commit is contained in:
+10
-9
@@ -52,10 +52,10 @@ bash Tools/emby_to_lidarr_sync.sh
|
||||
|
||||
### Notes
|
||||
|
||||
- Reads completions from the Emby activity log (`has finished playing` events)
|
||||
- Reads all MusicAlbum items from Emby and extracts AlbumArtist — primary album
|
||||
artists only, not guest features or tag credits
|
||||
- Filters out VA, Various Artists, and other metadata placeholders
|
||||
- Uses `searchForMissingAlbums: false` — adds monitoring without triggering a
|
||||
full album search; run Lidarr's own missing-album search afterwards if desired
|
||||
- Triggers `ArtistSearch` immediately after each successful add — no manual search needed
|
||||
- Activity log has a finite history; use `--days N` if the log has been pruned
|
||||
|
||||
---
|
||||
@@ -84,10 +84,11 @@ bash Tools/emby_to_sonarr_sync.sh
|
||||
|
||||
### Notes
|
||||
|
||||
- Uses `searchForMissingEpisodes: false` — adds monitoring without triggering
|
||||
episode searches; Sonarr's library scan will pick up existing files
|
||||
- Adds to the first accessible root folder in Sonarr (`/tv` by default)
|
||||
- Triggers `SeriesSearch` immediately after each successful add — Sonarr begins
|
||||
searching for missing episodes right away
|
||||
- Adds to the first accessible root folder in Sonarr
|
||||
- TVDB ID match preferred over title; title fallback handles edge cases
|
||||
- Requires `SONARR_EMBY_LIBRARIES` configured in `master.conf`
|
||||
|
||||
---
|
||||
|
||||
@@ -115,9 +116,9 @@ bash Tools/emby_to_radarr_sync.sh
|
||||
|
||||
### Notes
|
||||
|
||||
- Uses `searchForMovie: false` — adds monitoring without triggering movie
|
||||
searches; Radarr's library scan will pick up existing files
|
||||
- Adds to the first accessible root folder in Radarr (`/movies` by default)
|
||||
- Triggers `MoviesSearch` immediately after each successful add — Radarr begins
|
||||
searching for the movie right away
|
||||
- Adds to the first accessible root folder in Radarr
|
||||
- TMDB ID match preferred over title; title fallback handles edge cases
|
||||
|
||||
---
|
||||
|
||||
@@ -78,6 +78,9 @@ something new, write the tool. Store it here. Find it at 2am next time.
|
||||
**Lifecycle Tools** — Backup, setup, and migration support
|
||||
`container_data_export.sh`, `recreate_shares.sh`, `claude_startup.sh`
|
||||
|
||||
**Library Sync Bootstrap** — Close the gap between Emby and arr libraries
|
||||
`emby_to_lidarr_sync.sh`, `emby_to_sonarr_sync.sh`, `emby_to_radarr_sync.sh`
|
||||
|
||||
---
|
||||
|
||||
## ━━━ RELATIONSHIP TO OTHER FOLDERS ━━━
|
||||
@@ -122,6 +125,9 @@ The relationship is one-way: Tools act on state that other scripts have written.
|
||||
| `recreate_shares.sh` | Share directories missing after fresh install or disk rebuild | After fresh unRAID install or disk replacement on HOST2 |
|
||||
| `continuous_scripts_status.sh` | Need a live view of watchdog and fallback state | Any time — manual dashboard, no schedule |
|
||||
| `claude_startup.sh` | Claude Code session setup after reboot — symlinks persistent storage | After each unRAID reboot, or called by array_started.sh |
|
||||
| `emby_to_lidarr_sync.sh` | Add all Emby album artists not yet tracked in Lidarr | After Lidarr setup, database wipe, or when you suspect gaps |
|
||||
| `emby_to_sonarr_sync.sh` | Add all Emby TV series not yet tracked in Sonarr | After Sonarr setup, database wipe, or when you suspect gaps |
|
||||
| `emby_to_radarr_sync.sh` | Add all Emby movies not yet tracked in Radarr | After Radarr setup, database wipe, or when you suspect gaps |
|
||||
|
||||
---
|
||||
|
||||
@@ -145,6 +151,10 @@ Situation arises
|
||||
│ recreate_shares ◄── fresh HOST2 setup or disk rebuild │
|
||||
│ continuous_scripts_status ◄── manual status check at any time │
|
||||
│ claude_startup ◄── after each unRAID reboot │
|
||||
│ │
|
||||
│ emby_to_lidarr_sync ◄── Lidarr setup / database wipe / gap │
|
||||
│ emby_to_sonarr_sync ◄── Sonarr setup / database wipe / gap │
|
||||
│ emby_to_radarr_sync ◄── Radarr setup / database wipe / gap │
|
||||
└──────────────────────────────────────────────────────────────────────┘
|
||||
│
|
||||
▼
|
||||
|
||||
@@ -21,12 +21,33 @@
|
||||
# 3. For each played artist not in Lidarr → add to Lidarr
|
||||
#
|
||||
# ==============================================================================================
|
||||
# USAGE
|
||||
# OPERATIONAL SAFEGUARDS
|
||||
# ==============================================================================================
|
||||
#
|
||||
# emby_to_lidarr_sync.sh — add all played artists not in Lidarr
|
||||
# Root Required
|
||||
# acquire_lock requires root. Script exits cleanly if not root.
|
||||
#
|
||||
# Dry-Run Mode
|
||||
# --dry-run shows all artists that would be added without making any Lidarr API calls.
|
||||
# Always run first when closing the gap after a fresh Lidarr install or database wipe.
|
||||
#
|
||||
# Add-Only
|
||||
# Only adds artists to Lidarr. Items already tracked (by name) are skipped without
|
||||
# modification. Safe to run multiple times — the second run finds nothing to add.
|
||||
#
|
||||
# ==============================================================================================
|
||||
# CONFIGURATION (master_host*.conf)
|
||||
# ==============================================================================================
|
||||
#
|
||||
# HOST*_LIDARR_URL / HOST*_LIDARR_API_KEY — Lidarr connection (aliased by detect_hosts)
|
||||
# HOST*_EMBY_URL / HOST*_EMBY_API_KEY — Emby connection (aliased by detect_hosts)
|
||||
#
|
||||
# ==============================================================================================
|
||||
# RUNTIME MODES
|
||||
# ==============================================================================================
|
||||
#
|
||||
# emby_to_lidarr_sync.sh — add all album artists not in Lidarr
|
||||
# emby_to_lidarr_sync.sh --dry-run — show what would be added, no changes
|
||||
# emby_to_lidarr_sync.sh --days N — limit to plays in the last N days
|
||||
# emby_to_lidarr_sync.sh --log — verbose output
|
||||
#
|
||||
# ==============================================================================================
|
||||
|
||||
@@ -23,7 +23,29 @@
|
||||
# falling back to case-insensitive title comparison.
|
||||
#
|
||||
# ==============================================================================================
|
||||
# USAGE
|
||||
# OPERATIONAL SAFEGUARDS
|
||||
# ==============================================================================================
|
||||
#
|
||||
# Root Required
|
||||
# acquire_lock requires root. Script exits cleanly if not root.
|
||||
#
|
||||
# Dry-Run Mode
|
||||
# --dry-run shows all movies that would be added without making any Radarr API calls.
|
||||
# Always run first when closing the gap after a fresh Radarr install or database wipe.
|
||||
#
|
||||
# Add-Only
|
||||
# Only adds movies to Radarr. Items already tracked by TMDB ID or title are skipped
|
||||
# without modification. Safe to run multiple times — the second run finds nothing to add.
|
||||
#
|
||||
# ==============================================================================================
|
||||
# CONFIGURATION (master_host*.conf)
|
||||
# ==============================================================================================
|
||||
#
|
||||
# HOST*_RADARR_URL / HOST*_RADARR_API_KEY — Radarr connection (aliased by detect_hosts)
|
||||
# HOST*_EMBY_URL / HOST*_EMBY_API_KEY — Emby connection (aliased by detect_hosts)
|
||||
#
|
||||
# ==============================================================================================
|
||||
# RUNTIME MODES
|
||||
# ==============================================================================================
|
||||
#
|
||||
# emby_to_radarr_sync.sh — add all untracked movies to Radarr
|
||||
|
||||
@@ -23,7 +23,30 @@
|
||||
# falling back to case-insensitive title comparison.
|
||||
#
|
||||
# ==============================================================================================
|
||||
# USAGE
|
||||
# OPERATIONAL SAFEGUARDS
|
||||
# ==============================================================================================
|
||||
#
|
||||
# Root Required
|
||||
# acquire_lock requires root. Script exits cleanly if not root.
|
||||
#
|
||||
# Dry-Run Mode
|
||||
# --dry-run shows all series that would be added without making any Sonarr API calls.
|
||||
# Always run first when closing the gap after a fresh Sonarr install or database wipe.
|
||||
#
|
||||
# Add-Only
|
||||
# Only adds series to Sonarr. Items already tracked by TVDB ID or title are skipped
|
||||
# without modification. Safe to run multiple times — the second run finds nothing to add.
|
||||
#
|
||||
# ==============================================================================================
|
||||
# CONFIGURATION (master.conf / master_host*.conf)
|
||||
# ==============================================================================================
|
||||
#
|
||||
# SONARR_EMBY_LIBRARIES — Emby library names to scan (master.conf)
|
||||
# HOST*_SONARR_URL / HOST*_SONARR_API_KEY — Sonarr connection (aliased by detect_hosts)
|
||||
# HOST*_EMBY_URL / HOST*_EMBY_API_KEY — Emby connection (aliased by detect_hosts)
|
||||
#
|
||||
# ==============================================================================================
|
||||
# RUNTIME MODES
|
||||
# ==============================================================================================
|
||||
#
|
||||
# emby_to_sonarr_sync.sh — add all untracked series to Sonarr
|
||||
|
||||
Reference in New Issue
Block a user