From 95a6c7034a8df2063eb0ea4e2db3d55c79e5ef9c Mon Sep 17 00:00:00 2001 From: Matei Adriel Date: Sun, 28 Jan 2024 17:19:22 +0100 Subject: [PATCH] Swap out znc for soju --- hosts/nixos/lapetus/default.nix | 2 +- hosts/nixos/lapetus/services/soju.nix | 9 +++++++++ hosts/nixos/lapetus/services/znc.nix | 20 ++++++++++---------- 3 files changed, 20 insertions(+), 11 deletions(-) create mode 100644 hosts/nixos/lapetus/services/soju.nix diff --git a/hosts/nixos/lapetus/default.nix b/hosts/nixos/lapetus/default.nix index 53a9848..278e7f3 100644 --- a/hosts/nixos/lapetus/default.nix +++ b/hosts/nixos/lapetus/default.nix @@ -6,7 +6,7 @@ ./services/syncthing.nix ./services/whoogle.nix - ./services/znc.nix + ./services/soju.nix ./filesystems ./hardware ]; diff --git a/hosts/nixos/lapetus/services/soju.nix b/hosts/nixos/lapetus/services/soju.nix new file mode 100644 index 0000000..1e8c3c3 --- /dev/null +++ b/hosts/nixos/lapetus/services/soju.nix @@ -0,0 +1,9 @@ +{ + services.soju = { + enable = true; + extraConfig = '' + db sqlite3 /persist/state/soju/storage.db + message-store db + ''; + }; +} diff --git a/hosts/nixos/lapetus/services/znc.nix b/hosts/nixos/lapetus/services/znc.nix index 579b0b6..14d76fa 100644 --- a/hosts/nixos/lapetus/services/znc.nix +++ b/hosts/nixos/lapetus/services/znc.nix @@ -2,16 +2,16 @@ services.znc = { enable = true; # mutable = false; - confOptions = { - nick = "prescientmoon"; - networks.tilde = { - server = "eu.tilde.chat"; - port = 6697; - channels = [ "#meta" "#math" ]; - modules = [ - "simple_away" # marks me as away when disconnected - "sasl" # auto login - ]; + useLegacyConfig = false; + + config.User.prescientmoon = { + Network.tilde = { + Server = "eu.tilde.chat +6697"; + Chan."#meta" = { }; + Chan."#math" = { }; + Nick = "prescientmoon"; + LoadModule = [ "" ]; + JoinDelay = 2; # Avoid joining channels before auth }; }; };