From 1feaf2e4f663276b4fbe892c11a5a6d064e0e204 Mon Sep 17 00:00:00 2001
From: Nemo <commits@captnemo.in>
Date: Thu, 27 Jul 2023 13:36:00 +0530
Subject: [PATCH] Migrate Emby to the SSD, and configure backups

Note that creating the directory alone doesn't do much.
You still have to configure backups and schedule them in the UI.
---
 media/emby.tf | 19 ++++++++++++++++++-
 1 file changed, 18 insertions(+), 1 deletion(-)

diff --git a/media/emby.tf b/media/emby.tf
index db596ee..45ac281 100644
--- a/media/emby.tf
+++ a/media/emby.tf
@@ -11,12 +11,27 @@
   name  = "emby"
   image = docker_image.emby.image_id
 
+  # SSD holds both the cache and data
   volumes {
-    host_path      = "/mnt/xwing/config/emby"
+    host_path      = "/mnt/zwing/config/emby"
     container_path = "/config"
   }
 
+  # We keep the cache separate
+  # So the config directory isn't bloated
   volumes {
+    host_path      = "/mnt/zwing/cache/emby"
+    container_path = "/config/cache"
+  }
+
+  # We want backups on the HDD
+  volumes {
+    host_path = "/mnt/xwing/backups/config/emby"
+    container_path = "/backups"
+  }
+
+  # And mount the media as well
+  volumes {
     host_path      = "/mnt/xwing/media"
     container_path = "/media"
   }
@@ -36,6 +51,8 @@
   destroy_grace_seconds = 10
   must_run              = true
 
+  # This breaks every time we upgrade the kernel
+  # or the nvidia driver, and needs a reboot.
   # gpus = "all"
 
   # Running as lounge:tatooine
--
rgit 0.1.5