about summary refs log tree commit diff
path: root/modules/services
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2022-06-10 08:30:41 -0700
committerFranck Cuny <franck@fcuny.net>2022-06-10 08:31:17 -0700
commit00022f86a4efda0cd5c6de5708e78a5ddb079a22 (patch)
tree2d374e7ea7d374383ad81b40f340fd141e678b63 /modules/services
parentfix(unifi): configure correctly services.unifi for nixos 22.05 (diff)
downloadworld-00022f86a4efda0cd5c6de5708e78a5ddb079a22.tar.gz
fix(backups): exclude more files from the backups
We don't need to backup log files for grafana and sourcegraph.

Change-Id: I8ed6f6ce1270a12233cad268bcd12e28ac2785cf
Reviewed-on: https://cl.fcuny.net/c/world/+/383
Tested-by: CI
Reviewed-by: Franck Cuny <franck@fcuny.net>
Diffstat (limited to '')
-rw-r--r--modules/services/grafana/default.nix5
-rw-r--r--modules/services/sourcegraph/default.nix7
2 files changed, 11 insertions, 1 deletions
diff --git a/modules/services/grafana/default.nix b/modules/services/grafana/default.nix
index 773090b..fd80263 100644
--- a/modules/services/grafana/default.nix
+++ b/modules/services/grafana/default.nix
@@ -49,6 +49,9 @@ in {
       credentialsFile = secrets."acme/credentials".path;
     };
 
-    my.services.backup = { paths = [ "/var/lib/grafana" ]; };
+    my.services.backup = {
+      paths = [ "/var/lib/grafana" ];
+      exclude = [ "/var/lib/grafana/log/" ];
+    };
   };
 }
diff --git a/modules/services/sourcegraph/default.nix b/modules/services/sourcegraph/default.nix
index 6acf24c..e533b9d 100644
--- a/modules/services/sourcegraph/default.nix
+++ b/modules/services/sourcegraph/default.nix
@@ -41,6 +41,13 @@ in {
 
     my.services.backup = {
       paths = [ "/var/lib/sourcegraph/etc" "/var/lib/sourcegraph/data" ];
+      exclude = [
+        "/var/lib/sourcegraph/data/grafana/logs/"
+        "/var/lib/sourcegraph/data/jaeger.log"
+        "/var/lib/sourcegraph/data/grafana.log"
+        "/var/lib/sourcegraph/data/minio.log"
+        "/var/lib/sourcegraph/data/prometheus.log"
+      ];
     };
   };
 }