From 279ff6251173e161cc50d8ae03cb3cd2e90a61a4 Mon Sep 17 00:00:00 2001 From: sinanmohd Date: Mon, 3 Jun 2024 18:28:35 +0530 Subject: global: init global contains shared data between home-manager and nixos modules. they're just structured data, it's doesn't contain any module functionally in the normal sense, an example is preferred monospace font or user's mail id `config.global.userdata.email` --- os/kay/modules/acme.nix | 4 ++-- os/kay/modules/cgit.nix | 4 ++-- os/kay/modules/dendrite.nix | 2 +- os/kay/modules/mail.nix | 4 ++-- os/kay/modules/matrix-sliding-sync.nix | 2 +- os/kay/modules/sftp.nix | 2 +- os/kay/modules/www.nix | 2 +- 7 files changed, 10 insertions(+), 10 deletions(-) (limited to 'os/kay/modules') diff --git a/os/kay/modules/acme.nix b/os/kay/modules/acme.nix index f4ded0a..00819e7 100644 --- a/os/kay/modules/acme.nix +++ b/os/kay/modules/acme.nix @@ -1,6 +1,6 @@ { config, pkgs, ... }: let - email = config.userdata.email; - domain = config.userdata.domain; + email = config.global.userdata.email; + domain = config.global.userdata.domain; environmentFile = pkgs.writeText "acme-dns" "RFC2136_NAMESERVER='[2001:470:ee65::1]:53'"; diff --git a/os/kay/modules/cgit.nix b/os/kay/modules/cgit.nix index f8fb25c..0b0a6ec 100644 --- a/os/kay/modules/cgit.nix +++ b/os/kay/modules/cgit.nix @@ -1,8 +1,8 @@ { config, pkgs, ... }: let - domain = config.userdata.domain; - user = config.userdata.name; + domain = config.global.userdata.domain; + user = config.global.userdata.name; in { environment.systemPackages = with pkgs; [ diff --git a/os/kay/modules/dendrite.nix b/os/kay/modules/dendrite.nix index 8277e21..71266a5 100644 --- a/os/kay/modules/dendrite.nix +++ b/os/kay/modules/dendrite.nix @@ -1,7 +1,7 @@ { config, lib, pkgs, ... }: let - domain = config.userdata.domain; + domain = config.global.userdata.domain; database = { connection_string = "postgres:///dendrite?host=/run/postgresql"; max_open_conns = 90; diff --git a/os/kay/modules/mail.nix b/os/kay/modules/mail.nix index 79e4019..ee91f78 100644 --- a/os/kay/modules/mail.nix +++ b/os/kay/modules/mail.nix @@ -1,8 +1,8 @@ { config, ... }: let ipv6 = "2001:470:ee65::1337"; - domain = config.userdata.domain; + domain = config.global.userdata.domain; - username = config.userdata.name; + username = config.global.userdata.name; secret = "$argon2i$v=19$m=4096,t=3,p=1$SWV5aWU3YWUgZWFTNm9oc28gTGFvdDdlRG8ga2FTaWVjaDYgYWV0aDFHb28$O/sDv7oy9wUxFjvKoxB5o8ZnPvjYJo9DjX0C/AZQFF0"; email = [ "${username}@${domain}" diff --git a/os/kay/modules/matrix-sliding-sync.nix b/os/kay/modules/matrix-sliding-sync.nix index ebdc34d..03ab9fc 100644 --- a/os/kay/modules/matrix-sliding-sync.nix +++ b/os/kay/modules/matrix-sliding-sync.nix @@ -1,7 +1,7 @@ { config, ... }: let - domain = config.userdata.domain; + domain = config.global.userdata.domain; in { sops.secrets."matrix-${domain}/sliding_sync" = {}; diff --git a/os/kay/modules/sftp.nix b/os/kay/modules/sftp.nix index bbe055e..f3c3538 100644 --- a/os/kay/modules/sftp.nix +++ b/os/kay/modules/sftp.nix @@ -2,7 +2,7 @@ let storage = "/hdd/users"; - user = config.userdata.name; + user = config.global.userdata.name; pubKeys = config.users.users.${user}.openssh.authorizedKeys.keys; in { diff --git a/os/kay/modules/www.nix b/os/kay/modules/www.nix index 3891bf6..54eab65 100644 --- a/os/kay/modules/www.nix +++ b/os/kay/modules/www.nix @@ -1,7 +1,7 @@ { config, pkgs, lib, ... }: let - domain = config.userdata.domain; + domain = config.global.userdata.domain; fscusat = "fscusat.org"; mark = "themark.ing"; storage = "/hdd/users/sftp/shr"; -- cgit v1.2.3