about summary refs log tree commit diff
path: root/nixos/modules/services
diff options
context:
space:
mode:
authorLinus Heckemann <git@sphalerite.org>2023-06-01 17:03:42 +0200
committerLinus Heckemann <git@sphalerite.org>2023-06-02 18:11:44 +0200
commitc4f727c944203e8421976811d744122f3b833515 (patch)
treee227a413a5f86696d6e82cc0384c3f434d0162ed /nixos/modules/services
parent4f53efe34b3a8877ac923b9350c874e3dcd5dc0a (diff)
downloadnixlib-c4f727c944203e8421976811d744122f3b833515.tar
nixlib-c4f727c944203e8421976811d744122f3b833515.tar.gz
nixlib-c4f727c944203e8421976811d744122f3b833515.tar.bz2
nixlib-c4f727c944203e8421976811d744122f3b833515.tar.lz
nixlib-c4f727c944203e8421976811d744122f3b833515.tar.xz
nixlib-c4f727c944203e8421976811d744122f3b833515.tar.zst
nixlib-c4f727c944203e8421976811d744122f3b833515.zip
nixos/garage: allow unsafe replication modes, restart on config change
Diffstat (limited to 'nixos/modules/services')
-rw-r--r--nixos/modules/services/web-servers/garage.nix3
1 files changed, 2 insertions, 1 deletions
diff --git a/nixos/modules/services/web-servers/garage.nix b/nixos/modules/services/web-servers/garage.nix
index ebd41473939a..8b5734b5a2ce 100644
--- a/nixos/modules/services/web-servers/garage.nix
+++ b/nixos/modules/services/web-servers/garage.nix
@@ -49,7 +49,7 @@ in
 
           replication_mode = mkOption {
             default = "none";
-            type = types.enum ([ "none" "1" "2" "3" 1 2 3 ]);
+            type = types.enum ([ "none" "1" "2" "3" "2-dangerous" "3-dangerous" "3-degraded" 1 2 3 ]);
             apply = v: toString v;
             description = lib.mdDoc "Garage replication mode, defaults to none, see: <https://garagehq.deuxfleurs.fr/documentation/reference-manual/configuration/#replication-mode> for reference.";
           };
@@ -80,6 +80,7 @@ in
       after = [ "network.target" "network-online.target" ];
       wants = [ "network.target" "network-online.target" ];
       wantedBy = [ "multi-user.target" ];
+      restartTriggers = [ configFile ];
       serviceConfig = {
         ExecStart = "${cfg.package}/bin/garage server";