infra/nix/os/snippets/mycelium.nix

36 lines
640 B
Nix
Raw Normal View History

2024-05-25 11:35:26 +02:00
{
repoFlake,
nodeFlake,
nodeName,
config,
system,
lib,
2024-05-25 11:35:26 +02:00
...
}: let
cfg.autostart = false;
in {
2024-05-25 11:35:26 +02:00
imports = [
];
sops.secrets.mycelium-key = {
format = "binary";
sopsFile = repoFlake + "/secrets/${nodeName}/mycelium_priv_key.bin.enc";
};
services.mycelium = {
enable = true;
2024-07-26 14:08:24 +02:00
# package = nodeFlake.inputs.mycelium.packages.${system}.myceliumd;
2024-05-25 11:35:26 +02:00
keyFile = config.sops.secrets.mycelium-key.path;
addHostedPublicNodes = true;
peers = [
];
# tunName = "mycelium-pub";
extraArgs = [
];
};
systemd.services.mycelium.wantedBy = lib.mkIf (!cfg.autostart) (lib.mkForce []);
2024-05-25 11:35:26 +02:00
}