1 { pkgs, lib, config, hostName, hosts, ... }:
3 inherit (config) networking;
4 inherit (config.services) syncoid;
5 inherit (config.security) gnupg;
8 networking.nftables.ruleset = ''
9 add rule inet filter fw2net \
10 skuid "${syncoid.user}" \
12 ip daddr ${hosts.mermet.extraArgs.ipv4} \
14 comment "SSH to mermet"
16 security.gnupg.secrets."ssh/backup.ssh-ed25519" = {
19 users.groups.keys.members = [ syncoid.user ];
22 interval = "*-*-* *:05:00";
24 sshKey = gnupg.secrets."ssh/backup.ssh-ed25519".path;
28 #"--no-privilege-elevation"
32 after = [ gnupg.secrets."ssh/backup.ssh-ed25519".service ];
33 wants = [ gnupg.secrets."ssh/backup.ssh-ed25519".service ];
36 "${hostName}/home/julm/work" = {
38 target = "backup@mermet.${networking.domain}:rpool/backup/${hostName}/home/julm/work";
40 "backup@mermet.${networking.domain}:rpool/var/mail" = {
42 target = "${hostName}/backup/mermet/var/mail";
44 "backup@mermet.${networking.domain}:rpool/var/prosody" = {
46 target = "${hostName}/backup/mermet/var/prosody";
48 "backup@mermet.${networking.domain}:rpool/var/public-inbox" = {
50 target = "${hostName}/backup/mermet/var/public-inbox";
52 "backup@mermet.${networking.domain}:rpool/var/www" = {
54 target = "${hostName}/backup/mermet/var/www";
56 "backup@mermet.${networking.domain}:rpool/var/git" = {
58 target = "${hostName}/backup/mermet/var/git";
60 "backup@mermet.${networking.domain}:rpool/var/redis" = {
62 target = "${hostName}/backup/mermet/var/redis";
64 "backup@mermet.${networking.domain}:rpool/home/julm/mail" = {
66 target = "${hostName}/backup/mermet/home/julm/mail";
68 "backup@mermet.${networking.domain}:rpool/home/julm/log" = {
70 target = "${hostName}/backup/mermet/home/julm/log";