Skip to content

Instantly share code, notes, and snippets.

@JourneyOver
Last active December 1, 2025 21:51
Show Gist options
  • Select an option

  • Save JourneyOver/c14b3f2fc6187eed6bf7a9f20d9cab50 to your computer and use it in GitHub Desktop.

Select an option

Save JourneyOver/c14b3f2fc6187eed6bf7a9f20d9cab50 to your computer and use it in GitHub Desktop.
Plex Server with Real Debrid (RD) via Zurg on Windows

Ultimate Guide to Setting Up a Plex Server with Real Debrid (RD) via Zurg on Windows

This comprehensive guide walks you through setting up a Plex server integrated with Real Debrid using Zurg on a Windows system. It includes streamlined steps, troubleshooting tips, and optimizations for a seamless streaming experience.


Prerequisites

Before you begin, ensure you have the following:

  • Real Debrid Account: Obtain your API token from Real Debrid.
  • Windows System: Windows 10 or later (64-bit recommended).
  • Administrative Privileges: Required for installing services.
  • Tools:
    • WinFSP (Install with default settings for file system support).
    • Rclone (Download the Windows 64-bit zip, extract rclone.exe).
    • NSSM (Download the zip, extract nssm.exe).

Step 1: Download and Set Up Zurg

  1. Download Zurg:

    • Visit the Zurg releases page.
    • Download the latest release (e.g., zurg-vX.X.X-windows-amd64.zip).
    • Extract the contents to a folder, e.g., c:\zurg.
  2. Download Configuration Files:

    • From the Zurg repository, download:
      • config.yml
      • rclone.conf
      • scripts/plex_update.ps1
    • Place these files in the same folder as zurg.exe (e.g., c:\zurg).
  3. Copy Tools:

    • Copy rclone.exe, nssm.exe, and plex_update.ps1 into the c:\zurg folder.

    Your folder structure should look like this:

    c:\zurg\
    ├── zurg.exe
    ├── rclone.exe
    ├── nssm.exe
    ├── config.yml
    ├── rclone.conf
    ├── plex_update.ps1
    

Step 2: Configure Zurg and Rclone

  1. Edit config.yml:

    • Open config.yml in a text editor (e.g., Notepad++ or VS Code).
    • Replace the token: ... line with your Real Debrid API token:
      token: YOUR_REAL_DEBRID_TOKEN
    • Save the file.
  2. Edit rclone.conf:

    • Open rclone.conf in a text editor.
    • Ensure the url points to localhost:
      [zurg]
      type = webdav
      url = http://localhost:9999/dav
      vendor = other
      pacer_min_sleep = 0
      
    • Save the file.

Step 3: Set Up Zurg and Rclone as Windows Services

Run all commands from a Command Prompt or PowerShell with administrative privileges, navigated to the Zurg folder (e.g., cd c:\zurg).

3.1 Zurg Service

  1. Run:
    nssm.exe install zurg
  2. In the NSSM GUI:
    • Path: Browse and select c:\zurg\zurg.exe.
    • Startup directory: Set to c:\zurg.
    • Arguments: Leave blank.
    • I/O Tab: Configure logging for troubleshooting:
      • Output (stdout): c:\zurg\logs\zurg.log
      • Error (stderr): c:\zurg\logs\zurg_error.log
      • Create a logs folder in c:\zurg if it doesn't exist.
  3. Click Install Service.

3.2 Rclone Service

  1. Run:
    nssm.exe install rclone
  2. In the NSSM GUI:
    • Path: Browse and select c:\zurg\rclone.exe.
    • Startup directory: Set to c:\zurg.
    • Arguments:
      mount zurg: Z: --dir-cache-time 10s --vfs-cache-mode full --vfs-read-chunk-size 1M --vfs-read-chunk-size-limit 32M --no-console
      • Replace Z: with your preferred drive letter if needed.
    • I/O Tab: Configure logging for troubleshooting:
      • Output (stdout): c:\zurg\logs\rclone.log
      • Error (stderr): c:\zurg\logs\rclone_error.log
      • Ensure the logs folder exists in c:\zurg.
  3. Click Install Service.

Note: NSSM does not create log files by default. Configuring the I/O tab ensures logs are generated for debugging service issues.


Step 4: Start the Services

  1. Option 1: Using Windows Services App:

    • Press Win + R, type services.msc, and press Enter.
    • Locate rclone and zurg in the list.
    • Right-click each service and select Start.
    • start rclone before you start zurg
  2. Option 2: Using NSSM Commands:

    • Run the following commands in a Command Prompt or PowerShell with administrative privileges:
      nssm.exe start rclone
      nssm.exe start zurg
    • To verify the services are running, run:
      nssm.exe status rclone
      nssm.exe status zurg
  • By default, these services should start automatically after a system reboot.

Step 5: Verify the Setup

  1. Check the Mounted Drive:

    • Open File Explorer and look for the new drive (z: by default) under This PC.
    • You should see folders like movies, shows, anime, etc.
  2. Test WebDAV Access:

    • Open a web browser and navigate to http://localhost:9999/.
    • Confirm you can access the Zurg WebDAV interface.
  3. Troubleshooting:

    • If the drive doesn’t appear, ensure WinFSP is installed and both services are running.

Step 6: Optimize Rclone (Optional)

For improved performance, modify the Rclone service arguments:

  1. Open the Services app, stop both the rclone and zurg services.
  2. Run:
    nssm.exe edit rclone
  3. Update the Arguments field with:
    mount zurg: Z: --attr-timeout 10y --buffer-size 128M --dir-cache-time 10s --poll-interval 60s --vfs-cache-max-age 2M --vfs-cache-max-size 50G --vfs-cache-min-free-space 2G --vfs-cache-mode full --vfs-cache-poll-interval 30s --vfs-disk-space-total-size 100G --vfs-fast-fingerprint --vfs-read-ahead 64M --vfs-read-chunk-size 1M --vfs-read-chunk-size-limit 32M --vfs-read-wait 40ms --vfs-refresh --transfers 32 --checkers 32 --multi-thread-streams 8 --fast-list --no-console
  4. Click Apply, then restart both the rclone and zurg services.

Explanation of Key Parameters:

  • --vfs-cache-mode full: Ensures smooth streaming by caching files.
  • --vfs-read-chunk-size 1M and --vfs-read-chunk-size-limit 32M: Optimizes data transfer for streaming.
  • --vfs-cache-max-size 50G: Limits cache size to prevent disk space issues.
  • --transfers 32 --checkers 32: Increases parallel operations for faster access.

Step 7: Integrate with Plex (Optional)

To use your Zurg setup with Plex:

  1. Add Zurg Folders to Plex:

    • Open Plex and navigate to Settings > Libraries.
    • Add new libraries or edit existing ones to include paths like z:\movies, z:\shows, etc.
    • Refer to Plex's guide on editing libraries.
  2. Automate Library Updates:

    • Edit config.yml to enable automatic Plex library updates:
      • Uncomment the on_library_update line for Windows:
        on_library_update: '& powershell -ExecutionPolicy Bypass -File .\plex_update.ps1 --% "$args"'
      • Comment out the Linux/macOS line:
        #on_library_update: sh plex_update.sh "$@"
  3. Configure plex_update.ps1:

    • Open plex_update.ps1 in a text editor and update:
      # Plex server details
      $plexUrl = "http://YOUR_PLEX_SERVER_IP:32400"  # Replace with your Plex server IP
      $plexToken = "YOUR_PLEX_TOKEN"                 # Obtain from Plex settings
      # Replace with your mount
      $mount = "Z:"                                  # Match your Rclone drive letter
      # Log file path
      Start-Transcript -Path "C:\Zurg\logs\plex_update.log" -Append
      # Directories to update
      $directoriesToUpdate = @("Z:\movies", "Z:\anime", "Z:\shows", "Z:\movies4k", "Z:\shows4k")
    • Save the file.
  4. Add Content to Real Debrid:

    • Use tools like Debrid Media Manager or Stremio to add torrents or magnets to your Real Debrid account.
    • Zurg will sync the content to your mounted drive, and Plex will detect it via auto-scans.

Step 8: Troubleshooting Tips

  • Drive Not Showing in File Explorer:

    • Verify WinFSP is installed correctly.
    • Ensure both zurg and rclone services are running (services.msc).
    • Check rclone.conf for correct url (http://localhost:9999/dav).
  • Plex Not Detecting New Content:

    • Confirm the plex_update.ps1 script has the correct $plexUrl and $plexToken.
    • Check the log file (c:\zurg\logs\plex_update.log) for errors.
    • Manually trigger a library scan in Plex to test.
  • Performance Issues:

    • Use the optimized Rclone arguments from Step 6.
    • Ensure your system has sufficient RAM and CPU for caching and streaming.
  • Service Fails to Start:

    • Check NSSM logs (c:\zurg\logs\zurg.log, c:\zurg\logs\zurg_error.log, c:\zurg\logs\rclone.log, c:\Zurg\logs\rclone_error.log) for error details
    • Verify paths to zurg.exe and rclone.exe in NSSM configurations.
    • Use nssm.exe status [serviceName] to check service status

Step 9: Enjoy Your Streaming Setup!

Your Plex server is now integrated with Real Debrid via Zurg, providing access to a vast library of content. Stream movies, shows, and more with minimal buffering and automatic library updates. For further customization, explore the Zurg repository or Rclone documentation.

Happy streaming! 🎬

#Requires -RunAsAdministrator
<#
.SYNOPSIS
One-Click Installer/Uninstaller for Zurg on Windows
.DESCRIPTION
This script automates the setup of Zurg with Real Debrid, Rclone mount, and optional Plex integration, or uninstalls them.
It downloads required tools, configures files, installs Windows services, and starts them for install.
For uninstall, it stops and removes services and optionally the directory.
.NOTES
Run as administrator. Requires internet connection for downloads (install only).
#>
param(
[switch]$V # Verbose mode
)
# Configuration
$Script:Config = @{
DefaultZurgDir = "C:\zurg"
DefaultDrive = "Z"
TempDir = Join-Path $env:TEMP "zurg_install"
Urls = @{
WinFSP = "https://github.com/winfsp/winfsp/releases/download/v2.0/winfsp-2.0.23075.msi"
Rclone = "https://downloads.rclone.org/rclone-current-windows-amd64.zip"
NSSM = "https://nssm.cc/release/nssm-2.24.zip"
Zurg = "https://github.com/debridmediamanager/zurg-testing/releases/download/v0.9.3-final/zurg-v0.9.3-final-windows-amd64.zip"
Config = "https://raw.githubusercontent.com/debridmediamanager/zurg-testing/main/config.yml"
RcloneConf = "https://raw.githubusercontent.com/debridmediamanager/zurg-testing/main/rclone.conf"
PlexUpdate = "https://raw.githubusercontent.com/debridmediamanager/zurg-testing/main/scripts/plex_update.ps1"
}
}
# Functions
function Write-Log {
param ([string]$Message, [string]$Type = "INFO", [switch]$VerboseOnly = $false)
if ($VerboseOnly -and -not $V) { return }
$timestamp = Get-Date -Format "yyyy-MM-dd HH:mm:ss"
Write-Host "[$timestamp] [$Type] $Message"
}
function Write-Verbose {
param ([string]$Message)
Write-Log -Message $Message -Type "VERBOSE" -VerboseOnly
}
function Test-CommandExists {
param ([string]$Command)
return [bool](Get-Command $Command -ErrorAction SilentlyContinue)
}
function Download-File {
param ([string]$Url, [string]$Path)
try {
Write-Verbose "Downloading $Url to $Path"
Invoke-WebRequest -Uri $Url -OutFile $Path -ErrorAction Stop
} catch {
Write-Log "Failed to download $Url - $($_.Exception.Message)" "ERROR"
throw
}
}
function Extract-Zip {
param ([string]$ZipPath, [string]$Dest)
try {
Write-Verbose "Extracting $ZipPath to $Dest"
Expand-Archive -Path $ZipPath -DestinationPath $Dest -Force -ErrorAction Stop
} catch {
Write-Log "Failed to extract $ZipPath - $($_.Exception.Message)" "ERROR"
throw
}
}
function Download-And-Extract {
param ([string]$Url, [string]$Dest)
$zipPath = Join-Path $Script:Config.TempDir "temp.zip"
Download-File -Url $Url -Path $zipPath
Extract-Zip -ZipPath $zipPath -Dest $Dest
Remove-Item $zipPath -Force
}
function Get-UserInput {
param (
[string]$Prompt,
[string]$DefaultValue,
[switch]$Secure = $false
)
$inputPrompt = $Prompt
if ($DefaultValue) {
$inputPrompt += " (default: $DefaultValue)"
}
$inputPrompt += ": "
if ($Secure) {
$result = Read-Host -AsSecureString $inputPrompt
return [Runtime.InteropServices.Marshal]::PtrToStringAuto([Runtime.InteropServices.Marshal]::SecureStringToBSTR($result))
} else {
$result = Read-Host $inputPrompt
if ([string]::IsNullOrWhiteSpace($result) -and $DefaultValue) {
return $DefaultValue
}
return $result
}
}
function Test-WinFSPInstalled {
Write-Verbose "Checking if WinFSP is already installed..."
try {
$installedPrograms = Get-ItemProperty "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\*" -ErrorAction SilentlyContinue
$winfspInstalled = $installedPrograms | Where-Object {
$_.DisplayName -like "WinFsp 2023*" -or
$_.DisplayName -like "WinFsp*" # Fallback for other versions
}
if ($winfspInstalled) {
Write-Verbose "WinFSP found in registry: $($winfspInstalled.DisplayName)"
return $true
}
} catch {
Write-Verbose "Error checking registry for WinFSP: $($_.Exception.Message)"
}
# Additional check: Look for WinFSP in Program Files
$winfspPaths = @(
"${env:ProgramFiles}\WinFsp",
"${env:ProgramFiles(x86)}\WinFsp"
)
foreach ($path in $winfspPaths) {
if (Test-Path $path) {
Write-Verbose "WinFSP found in directory: $path"
return $true
}
}
Write-Verbose "WinFSP is not installed"
return $false
}
function Install-WinFSP {
if (Test-WinFSPInstalled) {
Write-Log "WinFSP already installed, skipping installation."
return
}
Write-Log "Installing WinFSP..."
# Create temp directory if it doesn't exist
if (-not (Test-Path $Script:Config.TempDir)) {
New-Item -ItemType Directory -Force -Path $Script:Config.TempDir | Out-Null
}
$winfspPath = Join-Path $Script:Config.TempDir "winfsp.msi"
Download-File -Url $Script:Config.Urls.WinFSP -Path $winfspPath
Write-Verbose "Installing WinFSP (this may take a moment)..."
$process = Start-Process msiexec.exe -ArgumentList "/i `"$winfspPath`" /quiet /norestart" -Wait -PassThru
if ($process.ExitCode -ne 0) {
throw "WinFSP installation failed with exit code $($process.ExitCode)"
}
# Verify installation was successful
Start-Sleep -Seconds 3 # Give time for installation to complete
if (-not (Test-WinFSPInstalled)) {
throw "WinFSP installation completed but verification failed. Please install WinFSP manually."
}
Write-Log "WinFSP installed successfully"
}
function Get-InstallationParameters {
$zurgDir = Get-UserInput -Prompt "Enter Zurg installation directory" -DefaultValue $Script:Config.DefaultZurgDir
$rdToken = Get-UserInput -Prompt "Enter your Real Debrid API token" -Secure:$true
$useOptimized = (Get-UserInput -Prompt "Use optimized rclone arguments? (y/n)" -DefaultValue "y").ToLower() -eq "y"
$integratePlex = (Get-UserInput -Prompt "Integrate with Plex? (y/n)" -DefaultValue "n").ToLower() -eq "y"
$driveLetter = (Get-UserInput -Prompt "Enter drive letter for mount" -DefaultValue $Script:Config.DefaultDrive).ToUpper()
return @{
ZurgDir = $zurgDir
RdToken = $rdToken
UseOptimized = $useOptimized
IntegratePlex = $integratePlex
DriveLetter = "${driveLetter}:"
LogsDir = Join-Path $zurgDir "logs"
}
}
function Initialize-Directories {
param ($Params)
$directories = @($Params.ZurgDir, $Params.LogsDir, $Script:Config.TempDir)
foreach ($dir in $directories) {
if (-not (Test-Path $dir)) {
New-Item -ItemType Directory -Force -Path $dir | Out-Null
Write-Verbose "Created directory: $dir"
}
}
}
function Install-Tools {
param ($Params)
Write-Log "Downloading and installing required tools..."
# Install Rclone
Write-Verbose "Installing Rclone..."
Download-And-Extract -Url $Script:Config.Urls.Rclone -Dest $Script:Config.TempDir
$rcloneExtracted = Get-ChildItem $Script:Config.TempDir | Where-Object { $_.Name -like "rclone-*" } | Select-Object -First 1
Copy-Item (Join-Path $rcloneExtracted.FullName "rclone.exe") $Params.ZurgDir
# Install NSSM
Write-Verbose "Installing NSSM..."
Download-And-Extract -Url $Script:Config.Urls.NSSM -Dest $Script:Config.TempDir
$nssmExtracted = Get-ChildItem $Script:Config.TempDir | Where-Object { $_.Name -like "nssm-*" } | Select-Object -First 1
Copy-Item (Join-Path $nssmExtracted.FullName "win64\nssm.exe") $Params.ZurgDir
# Install Zurg
Write-Verbose "Installing Zurg..."
Download-And-Extract -Url $Script:Config.Urls.Zurg -Dest $Params.ZurgDir
}
function Install-Configuration {
param ($Params)
Write-Log "Downloading and configuring files..."
# Download configuration files
Download-File -Url $Script:Config.Urls.Config -Path (Join-Path $Params.ZurgDir "config.yml")
Download-File -Url $Script:Config.Urls.RcloneConf -Path (Join-Path $Params.ZurgDir "rclone.conf")
if ($Params.IntegratePlex) {
Download-File -Url $Script:Config.Urls.PlexUpdate -Path (Join-Path $Params.ZurgDir "plex_update.ps1")
}
# Configure config.yml
$configPath = Join-Path $Params.ZurgDir "config.yml"
$configContent = Get-Content $configPath -Raw
$configContent = $configContent -replace 'token: .*', "token: $($Params.RdToken)"
$configContent = $configContent -replace [regex]::Escape('on_library_update: sh plex_update.sh "$@"'), '#on_library_update: sh plex_update.sh "$@"'
if ($Params.IntegratePlex) {
$configContent = $configContent -replace [regex]::Escape('#on_library_update: ''& powershell -ExecutionPolicy Bypass -File .\plex_update.ps1 --% "$args"'''), 'on_library_update: ''& powershell -ExecutionPolicy Bypass -File .\plex_update.ps1 --% "$args"'''
}
Set-Content $configPath $configContent
# Configure rclone.conf
$rcloneConfPath = Join-Path $Params.ZurgDir "rclone.conf"
$rcloneConfContent = Get-Content $rcloneConfPath -Raw
$rcloneConfContent = $rcloneConfContent -replace 'url = http://zurg:9999/dav', 'url = http://localhost:9999/dav'
Set-Content $rcloneConfPath $rcloneConfContent
Write-Verbose "Configuration files updated successfully"
}
function Install-Services {
param ($Params)
$nssmPath = Join-Path $Params.ZurgDir "nssm.exe"
if (-not (Test-Path $nssmPath)) {
throw "NSSM not found at $nssmPath"
}
# Zurg service - only set stderr since Zurg handles its own logging
Write-Log "Installing Zurg service..."
& $nssmPath install zurg (Join-Path $Params.ZurgDir "zurg.exe")
& $nssmPath set zurg AppDirectory $Params.ZurgDir
& $nssmPath set zurg AppStderr (Join-Path $Params.LogsDir "zurg_error.log")
& $nssmPath set zurg Description "Zurg - Real Debrid media server"
# Rclone service - keep both stdout and stderr
Write-Log "Installing Rclone service..."
$rcloneExe = Join-Path $Params.ZurgDir "rclone.exe"
& $nssmPath install rclone $rcloneExe
& $nssmPath set rclone AppDirectory $Params.ZurgDir
if ($Params.UseOptimized) {
$rcloneArgs = "mount zurg: $($Params.DriveLetter) --attr-timeout 10y --buffer-size 128M --dir-cache-time 10s --poll-interval 60s --vfs-cache-max-age 2M --vfs-cache-max-size 50G --vfs-cache-min-free-space 2G --vfs-cache-mode full --vfs-cache-poll-interval 30s --vfs-disk-space-total-size 100G --vfs-fast-fingerprint --vfs-read-ahead 64M --vfs-read-chunk-size 1M --vfs-read-chunk-size-limit 32M --vfs-read-wait 40ms --vfs-refresh --transfers 32 --checkers 32 --multi-thread-streams 8 --no-console"
} else {
$rcloneArgs = "mount zurg: $($Params.DriveLetter) --dir-cache-time 10s --vfs-cache-mode full --vfs-read-chunk-size 1M --vfs-read-chunk-size-limit 32M --no-console"
}
& $nssmPath set rclone AppParameters $rcloneArgs
& $nssmPath set rclone AppStdout (Join-Path $Params.LogsDir "rclone.log")
& $nssmPath set rclone AppStderr (Join-Path $Params.LogsDir "rclone_error.log")
& $nssmPath set rclone Description "Rclone mount for Zurg"
}
function Start-Services {
param ($Params)
$nssmPath = Join-Path $Params.ZurgDir "nssm.exe"
Write-Log "Starting services..."
& $nssmPath start zurg
Start-Sleep -Seconds 2
& $nssmPath start rclone
Write-Verbose "Services started. Checking status..."
# Verify services are running
$zurgStatus = & $nssmPath status zurg
$rcloneStatus = & $nssmPath status rclone
Write-Verbose "Zurg service status: $zurgStatus"
Write-Verbose "Rclone service status: $rcloneStatus"
}
function Install-Zurg {
try {
Write-Log "Starting Zurg installation..."
$params = Get-InstallationParameters
Initialize-Directories -Params $params
# Check and install WinFSP first (before downloading other tools)
Install-WinFSP
Install-Tools -Params $params
Install-Configuration -Params $params
Install-Services -Params $params
Start-Services -Params $params
# Cleanup
Remove-Item $Script:Config.TempDir -Recurse -Force -ErrorAction SilentlyContinue
Write-Log "Installation complete! Check logs in $($params.LogsDir) for any issues."
if ($params.IntegratePlex) {
Write-Log "Remember to edit plex_update.ps1 with your Plex server details."
}
} catch {
Write-Log "Installation failed: $($_.Exception.Message)" "ERROR"
Write-Log "Stack trace: $($_.ScriptStackTrace)" "ERROR"
exit 1
}
}
function Uninstall-Zurg {
try {
$zurgDir = Get-UserInput -Prompt "Enter Zurg installation directory to uninstall" -DefaultValue $Script:Config.DefaultZurgDir
if (-not (Test-Path $zurgDir)) {
Write-Log "Zurg directory $zurgDir does not exist. Nothing to uninstall." "WARNING"
return
}
$nssmPath = Join-Path $zurgDir "nssm.exe"
if (Test-Path $nssmPath) {
# Stop and remove services
$services = @("zurg", "rclone")
foreach ($service in $services) {
Write-Verbose "Stopping $service service..."
& $nssmPath stop $service 2>$null
Start-Sleep -Seconds 1
Write-Verbose "Removing $service service..."
& $nssmPath remove $service confirm 2>$null
}
} else {
Write-Log "NSSM not found, skipping service removal" "WARNING"
}
# Optionally remove directory
$removeDir = (Get-UserInput -Prompt "Remove installation directory $zurgDir? (y/n)" -DefaultValue "y").ToLower() -eq "y"
if ($removeDir) {
Write-Log "Removing directory $zurgDir..."
Remove-Item $zurgDir -Recurse -Force -ErrorAction SilentlyContinue
}
# Always ask about uninstalling WinFSP if it's installed
if (Test-WinFSPInstalled) {
$uninstallWinfsp = (Get-UserInput -Prompt "Uninstall WinFSP? (y/n)" -DefaultValue "n").ToLower() -eq "y"
if ($uninstallWinfsp) {
Write-Log "Uninstalling WinFSP..."
$process = Start-Process msiexec.exe -ArgumentList "/x {E4C768C9-0ED1-4E8D-9B05-CC533F7D1B1A} /quiet /norestart" -Wait -PassThru
if ($process.ExitCode -eq 0) {
Write-Log "WinFSP uninstalled successfully"
} else {
Write-Log "WinFSP uninstallation may have failed with exit code $($process.ExitCode)" "WARNING"
}
} else {
Write-Verbose "WinFSP was left installed as requested"
}
}
Write-Log "Uninstallation complete."
} catch {
Write-Log "Uninstallation failed: $($_.Exception.Message)" "ERROR"
Write-Log "Stack trace: $($_.ScriptStackTrace)" "ERROR"
exit 1
}
}
# Main execution
try {
Write-Log "Zurg Installer/Uninstaller for Windows"
Write-Log "======================================"
if ($V) {
Write-Log "Verbose mode enabled"
}
$choice = Get-UserInput -Prompt "Choose action: 1) Install 2) Uninstall" -DefaultValue "1"
switch ($choice) {
"1" { Install-Zurg }
"2" { Uninstall-Zurg }
default {
Write-Log "Invalid choice. Defaulting to Install." "WARNING"
Install-Zurg
}
}
} catch {
Write-Log "Script execution failed: $($_.Exception.Message)" "ERROR"
exit 1
} finally {
Write-Log "Script execution completed"
}
@profucius
Copy link

Thanks for sharing this! I already had my Plex/Zurg/Rclone set up, but your steps mirror the same I took when I did mine. However your optional steps at the end were the secret sauce I was missing before; Auto-updating Plex, and improved Rclone config.

@JourneyOver
Copy link
Author

I have now added an automated method to help set this all up!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment