mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-21 12:59:04 +02:00
nixos/prometheus-exporters: fix default firewall filter
Instead of always using the default port of one exporter for its default firewall filter, the port from the current service configuration is used.
This commit is contained in:
parent
0ecc8b9a56
commit
5d51096839
|
@ -84,7 +84,8 @@ let
|
||||||
};
|
};
|
||||||
firewallFilter = mkOption {
|
firewallFilter = mkOption {
|
||||||
type = types.str;
|
type = types.str;
|
||||||
default = "-p tcp -m tcp --dport ${toString port}";
|
default = "-p tcp -m tcp --dport ${toString cfg.${name}.port}";
|
||||||
|
defaultText = "-p tcp -m tcp --dport ${toString port}";
|
||||||
example = literalExample ''
|
example = literalExample ''
|
||||||
"-i eth0 -p tcp -m tcp --dport ${toString port}"
|
"-i eth0 -p tcp -m tcp --dport ${toString port}"
|
||||||
'';
|
'';
|
||||||
|
|
Loading…
Reference in a new issue