From 0a011746579bdc753c00c069f6cc218b1647993b Mon Sep 17 00:00:00 2001 From: Ingolf Wagner Date: Wed, 29 Apr 2020 20:27:49 +0200 Subject: [PATCH] restic: add pepe as backup target --- configs/mobi/restic.nix | 1 + configs/sputnik/configuration.nix | 1 + configs/sputnik/restic.nix | 8 ++++++++ configs/workhorse/configuration.nix | 1 - configs/workhorse/restic.nix | 8 -------- system/all/restic.nix | 8 +++++++- system/desktop/restic.nix | 6 +----- system/server/default.nix | 1 - system/server/restic.nix | 9 --------- 9 files changed, 18 insertions(+), 25 deletions(-) create mode 100644 configs/sputnik/restic.nix delete mode 100644 configs/workhorse/restic.nix delete mode 100644 system/server/restic.nix diff --git a/configs/mobi/restic.nix b/configs/mobi/restic.nix index 88fad0c..2ef97d9 100644 --- a/configs/mobi/restic.nix +++ b/configs/mobi/restic.nix @@ -1,5 +1,6 @@ { backup.services.restic = { + "on-pepe.insecure".enable = false; "on-porani.insecure".enable = false; "on-workhorse.private".enable = false; "on-workout.private".enable = false; diff --git a/configs/sputnik/configuration.nix b/configs/sputnik/configuration.nix index fba95f6..c7f78ac 100644 --- a/configs/sputnik/configuration.nix +++ b/configs/sputnik/configuration.nix @@ -6,6 +6,7 @@ ./nginx.nix ./tinc.nix + ./restic.nix #./syncplay.nix #./mail-server.nix diff --git a/configs/sputnik/restic.nix b/configs/sputnik/restic.nix new file mode 100644 index 0000000..18c216a --- /dev/null +++ b/configs/sputnik/restic.nix @@ -0,0 +1,8 @@ +{ + backup.services.restic = { + "on-pepe.private".enable = false; + "on-porani.insecure".enable = false; + "on-workhorse.private".enable = false; + "on-workout.private".enable = false; + }; +} diff --git a/configs/workhorse/configuration.nix b/configs/workhorse/configuration.nix index a9b3efe..678191a 100644 --- a/configs/workhorse/configuration.nix +++ b/configs/workhorse/configuration.nix @@ -16,7 +16,6 @@ ./mail-fetcher.nix ./packages.nix ./prometheus.nix - ./restic.nix ./syncthing.nix ./taskserver.nix ./tinc.nix diff --git a/configs/workhorse/restic.nix b/configs/workhorse/restic.nix deleted file mode 100644 index 1464a79..0000000 --- a/configs/workhorse/restic.nix +++ /dev/null @@ -1,8 +0,0 @@ -{ config, ... }: { - - backup.services.restic = { - "on-porani.insecure".enable = true; - "on-workhorse.private".enable = true; - }; - -} diff --git a/system/all/restic.nix b/system/all/restic.nix index 9cd6cb7..724e01c 100644 --- a/system/all/restic.nix +++ b/system/all/restic.nix @@ -8,10 +8,16 @@ }; config = let - servers = [ "porani.insecure" "workhorse.private" "workout.private" ]; + servers = [ + "porani.insecure" + "workhorse.private" + "workout.private" + "pepe.private" + ]; dirs = config.backup.all.restic.dirs; setup = server: { + enable = lib.mkDefault true; passwordFile = toString ; repo = "sftp::backup/remote-${config.networking.hostName}"; requires = [ ]; diff --git a/system/desktop/restic.nix b/system/desktop/restic.nix index dde4f7c..1a29092 100644 --- a/system/desktop/restic.nix +++ b/system/desktop/restic.nix @@ -1,10 +1,6 @@ { lib, ... }: { - backup.services.restic = { - "on-porani.insecure".enable = lib.mkDefault true; - "on-workhorse.private".enable = lib.mkDefault true; - "on-workout.private".enable = lib.mkDefault true; - }; + backup.services.restic = { "on-porani.insecure".enable = false; }; backup.all.restic.dirs = [ "/home/palo/.password-store" ]; diff --git a/system/server/default.nix b/system/server/default.nix index cd5c7ea..f85e232 100644 --- a/system/server/default.nix +++ b/system/server/default.nix @@ -6,7 +6,6 @@ ./initssh.nix ./graylog-exporter.nix ./prometheus-exporters.nix - ./restic.nix ]; # make sure laptops stay awake when closing the montior diff --git a/system/server/restic.nix b/system/server/restic.nix deleted file mode 100644 index 0a1f3d8..0000000 --- a/system/server/restic.nix +++ /dev/null @@ -1,9 +0,0 @@ -{ lib, ... }: { - - backup.services.restic = { - "on-porani.insecure".enable = lib.mkDefault true; - "on-workhorse.private".enable = lib.mkDefault true; - "on-workout.private".enable = lib.mkDefault true; - }; - -}