diff options
author | Azat Bahawi <azat@bahawi.net> | 2024-04-21 02:15:42 +0300 |
---|---|---|
committer | Azat Bahawi <azat@bahawi.net> | 2024-04-21 02:15:42 +0300 |
commit | e6ed60548397627bf10f561f9438201dbba0a36e (patch) | |
tree | f9a84c5957d2cc4fcd148065ee9365a0c851ae1c /modules/murmur.nix | |
parent | 2024-04-18 (diff) |
2024-04-21
Diffstat (limited to 'modules/murmur.nix')
-rw-r--r-- | modules/murmur.nix | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/modules/murmur.nix b/modules/murmur.nix new file mode 100644 index 0000000..7621c9e --- /dev/null +++ b/modules/murmur.nix @@ -0,0 +1,32 @@ +{ + config, + inputs, + lib, + ... +}: +with lib; +let + cfg = config.nixfiles.modules.murmur; +in +{ + options.nixfiles.modules.murmur.enable = mkEnableOption "Murmur"; + + config = mkIf cfg.enable { + ark.directories = [ "/var/lib/murmur" ]; + + secrets.murmur-environment = { + file = "${inputs.self}/secrets/murmur-environment"; + owner = "murmur"; + group = "murmur"; + }; + + services.murmur = { + enable = true; + openFirewall = true; + logDays = -1; + registerName = mkDefault my.domain.shire; + password = "$MURMUR_PASSWORD"; + environmentFile = config.secrets."murmur-environment".path; + }; + }; +} |