diff options
author | github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> | 2024-03-30 00:12:08 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-30 00:12:08 +0000 |
commit | 506e353092183a01765b3612b8ac6b46884a79c2 (patch) | |
tree | 0a8cf6add24ef27eafbdd3f7a23a858596dde7d1 /nixos/modules/services/networking/mycelium.nix | |
parent | 201e6de9c789e8d72dd73f453aef222ad904e58c (diff) | |
parent | cd75d22750541115d5e3876838645d2d9123c842 (diff) |
Merge master into haskell-updates
Diffstat (limited to 'nixos/modules/services/networking/mycelium.nix')
-rw-r--r-- | nixos/modules/services/networking/mycelium.nix | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/nixos/modules/services/networking/mycelium.nix b/nixos/modules/services/networking/mycelium.nix index 9c4bca7c68618..9487a5daafee0 100644 --- a/nixos/modules/services/networking/mycelium.nix +++ b/nixos/modules/services/networking/mycelium.nix @@ -1,4 +1,4 @@ -{ config, pkgs, lib, ... }: +{ config, pkgs, lib, utils, ... }: let cfg = config.services.mycelium; @@ -46,6 +46,15 @@ in Adds the hosted peers from https://github.com/threefoldtech/mycelium#hosted-public-nodes. ''; }; + extraArgs = lib.mkOption { + type = lib.types.listOf lib.types.str; + default = [ ]; + description = '' + Extra command-line arguments to pass to mycelium. + + See `mycelium --help` for all available options. + ''; + }; }; config = lib.mkIf cfg.enable { networking.firewall.allowedTCPPorts = lib.optionals cfg.openFirewall [ 9651 ]; @@ -87,6 +96,7 @@ in ) "--tun-name" "mycelium" + "${utils.escapeSystemdExecArgs cfg.extraArgs}" ] ++ (lib.optional (cfg.addHostedPublicNodes || cfg.peers != [ ]) "--peers") ++ cfg.peers ++ (lib.optionals cfg.addHostedPublicNodes [ @@ -130,4 +140,3 @@ in maintainers = with lib.maintainers; [ flokli lassulus ]; }; } - |