mirror of
https://git.selfprivacy.org/SelfPrivacy/selfprivacy-nixos-config.git
synced 2024-09-08 20:16:56 +00:00
44 lines
2 KiB
Nix
44 lines
2 KiB
Nix
jsonData: { lib, ... }:
|
|
{
|
|
selfprivacy = jsonData // {
|
|
hostname = lib.attrsets.attrByPath [ "hostname" ] null jsonData;
|
|
domain = lib.attrsets.attrByPath [ "domain" ] null jsonData;
|
|
timezone = lib.attrsets.attrByPath [ "timezone" ] "Europe/Uzhgorod" jsonData;
|
|
stateVersion = lib.attrsets.attrByPath [ "stateVersion" ] "22.05" jsonData;
|
|
username = lib.attrsets.attrByPath [ "username" ] null jsonData;
|
|
hashedMasterPassword = lib.attrsets.attrByPath [ "hashedMasterPassword" ] null jsonData;
|
|
sshKeys = lib.attrsets.attrByPath [ "sshKeys" ] [ ] jsonData;
|
|
dns = {
|
|
provider = lib.attrsets.attrByPath [ "dns" "provider" ] "CLOUDFLARE" jsonData;
|
|
useStagingACME = lib.attrsets.attrByPath [ "dns" "useStagingACME" ] false jsonData;
|
|
};
|
|
backup = {
|
|
bucket = lib.attrsets.attrByPath [ "backup" "bucket" ] (lib.attrsets.attrByPath [ "backblaze" "bucket" ] "" jsonData) jsonData;
|
|
};
|
|
server = {
|
|
provider = lib.attrsets.attrByPath [ "server" "provider" ] "HETZNER" jsonData;
|
|
};
|
|
bitwarden = {
|
|
enable = lib.attrsets.attrByPath [ "bitwarden" "enable" ] false jsonData;
|
|
location = lib.attrsets.attrByPath [ "bitwarden" "location" ] "sda1" jsonData;
|
|
};
|
|
gitea = {
|
|
enable = lib.attrsets.attrByPath [ "gitea" "enable" ] false jsonData;
|
|
location = lib.attrsets.attrByPath [ "gitea" "location" ] "sda1" jsonData;
|
|
};
|
|
jitsi = {
|
|
enable = lib.attrsets.attrByPath [ "jitsi" "enable" ] false jsonData;
|
|
};
|
|
ssh = {
|
|
enable = lib.attrsets.attrByPath [ "ssh" "enable" ] true jsonData;
|
|
rootKeys = lib.attrsets.attrByPath [ "ssh" "rootKeys" ] [ "" ] jsonData;
|
|
passwordAuthentication = lib.attrsets.attrByPath [ "ssh" "passwordAuthentication" ] true jsonData;
|
|
};
|
|
email = {
|
|
location = lib.attrsets.attrByPath [ "email" "location" ] "sda1" jsonData;
|
|
};
|
|
users = lib.attrsets.attrByPath [ "users" ] [ ] jsonData;
|
|
volumes = lib.attrsets.attrByPath [ "volumes" ] [ ] jsonData;
|
|
};
|
|
}
|