forked from aylac.top/nixcfg
this repo has no description

added radicale

Changed files
+40 -1
hosts
nanpi
modules
nixos
profiles
backups
snippets
tailnet
+24 -1
hosts/nanpi/services.nix
···
reverse_proxy ${config.mySnippets.tailnet.networkMap.qbittorrent.hostName}:${toString config.mySnippets.tailnet.networkMap.qbittorrent.port}
'';
};
+
+
"${config.mySnippets.tailnet.networkMap.radicale.vHost}" = {
+
extraConfig = ''
+
bind tailscale/radicale
+
encode zstd gzip
+
reverse_proxy ${config.mySnippets.tailnet.networkMap.radicale.hostName}:${toString config.mySnippets.tailnet.networkMap.radicale.port}
+
'';
+
};
};
# it's failing to build because it can't download some stuff
···
dataDir = "${dataDirectory}/jellyfin";
};
-
# because of the lack of forwarding the ssh because of the tunnel, repo origins have to be added like this, and nobody can pull your repos
+
radicale = {
+
enable = true;
+
settings = {
+
server = {
+
hosts = ["0.0.0.0:${toString config.mySnippets.tailnet.networkMap.radicale.port}" "[::]:${toString config.mySnippets.tailnet.networkMap.radicale.port}"];
+
};
+
auth = {
+
type = "htpasswd";
+
htpasswd_filename = "/var/lib/radicale/users";
+
htpasswd_encryption = "autodetect";
+
};
+
storage = {
+
filesystem_folder = "/var/lib/radicale/collections";
+
};
+
};
+
};
};
}
+10
modules/nixos/profiles/backups/default.nix
···
repository = mkRepoA "passwords";
}
);
+
+
radicale = lib.mkIf config.services.radicale.enable (
+
config.mySnippets.restic
+
// {
+
backupCleanupCommand = start "radicale";
+
backupPrepareCommand = stop "radicale";
+
paths = ["/var/lib/radicale"];
+
repository = mkRepoA "radicale";
+
}
+
);
};
};
}
+6
modules/snippets/tailnet/default.nix
···
port = 2283;
vHost = "immich.${config.mySnippets.tailnet.name}";
};
+
+
radicale = {
+
hostName = "nanpi";
+
port = 5232;
+
vHost = "radicale.${config.mySnippets.tailnet.name}";
+
};
};
};
};