Vanguard media stack: ingest, copyparty, Syncthing, normalize sweep, Authentik, Jellyfin + Vanguard Metadata plugin, MariaDB, Gitea, bot runtime

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
2026-10-30 15:43:30 -05:00
commit c602a6ff52
66 changed files with 4229 additions and 0 deletions

View File

@@ -0,0 +1,65 @@
#!/bin/bash
# Build Release and produce dist/VanguardMetadata_<version>.zip (DLLs + meta.json) ready to drop into
# Jellyfin's plugins folder, plus dist/manifest.json for serving as a plugin repository.
set -euo pipefail
cd "$(dirname "$0")"
command -v yq >/dev/null 2>&1 || true
get() { grep -E "^$1:" build.yaml | head -1 | sed -E 's/^[a-zA-Z]+: *"?([^"]*)"?$/\1/'; }
NAME=$(get name); GUID=$(get guid); VERSION=$(get version); ABI=$(get targetAbi); OVERVIEW=$(get overview); OWNER=$(get owner); CATEGORY=$(get category)
DESC=$(python3 -c "import yaml,sys; print(yaml.safe_load(open('build.yaml'))['description'].strip())")
CHANGELOG=$(python3 -c "import yaml,sys; print(yaml.safe_load(open('build.yaml'))['changelog'].strip())")
dotnet test Jellyfin.Plugin.Vanguard.Tests --nologo -v q
dotnet build Jellyfin.Plugin.Vanguard -c Release --nologo -v q
OUT=Jellyfin.Plugin.Vanguard/bin/Release/net10.0
STAGE=dist/stage; rm -rf dist; mkdir -p "$STAGE"
cp "$OUT/Jellyfin.Plugin.Vanguard.dll" "$OUT/Jellyfin.Plugin.Vanguard.Core.dll" "$STAGE/"
TS=$(date -u +%Y-%m-%dT%H:%M:%SZ)
cat > "$STAGE/meta.json" <<JSON
{
"category": "$CATEGORY",
"changelog": $(python3 -c "import json,sys; print(json.dumps(sys.argv[1]))" "$CHANGELOG"),
"description": $(python3 -c "import json,sys; print(json.dumps(sys.argv[1]))" "$DESC"),
"guid": "$GUID",
"name": "$NAME",
"overview": "$OVERVIEW",
"owner": "$OWNER",
"targetAbi": "$ABI",
"timestamp": "$TS",
"version": "$VERSION",
"status": "Active",
"autoUpdate": true,
"imagePath": ""
}
JSON
ZIP="dist/VanguardMetadata_${VERSION}.zip"
( cd "$STAGE" && zip -q -r "../../$ZIP" . )
SUM=$(md5sum "$ZIP" | cut -d' ' -f1)
# repository manifest (serve dist/ at https://HOST/plugins/ and add that URL + manifest.json in Jellyfin)
cat > dist/manifest.json <<JSON
[
{
"guid": "$GUID",
"name": "$NAME",
"description": $(python3 -c "import json,sys; print(json.dumps(sys.argv[1]))" "$DESC"),
"overview": "$OVERVIEW",
"owner": "$OWNER",
"category": "$CATEGORY",
"imageUrl": "",
"versions": [
{
"version": "$VERSION",
"changelog": $(python3 -c "import json,sys; print(json.dumps(sys.argv[1]))" "$CHANGELOG"),
"targetAbi": "$ABI",
"sourceUrl": "https://PLUGIN_HOST/plugins/VanguardMetadata_${VERSION}.zip",
"checksum": "$SUM",
"timestamp": "$TS"
}
]
}
]
JSON
rm -rf "$STAGE"
echo "built: $ZIP (md5 $SUM)"
echo "install (manual): python3 -m zipfile -e $ZIP \"/srv/appdata/jellyfin/config/plugins/${NAME}_${VERSION}/\" (as uid 1000; Debian has no unzip) then restart jellyfin"