metrics: fix iptables rules
This commit is contained in:
@@ -7,13 +7,13 @@
|
||||
enabledCollectors = [ "systemd" ];
|
||||
};
|
||||
|
||||
systemd.services.prometheus-node-exporter.serviceConfig = {
|
||||
# TODO: Define allowed IPs
|
||||
# IPAddressDeny = "any";
|
||||
# IPAddressAllow = [
|
||||
# values.chapel.ipv4
|
||||
# values.chapel.ipv6
|
||||
# ];
|
||||
networking.firewall = {
|
||||
# TODO: Move this into the node-exporter systemd service
|
||||
allowedTCPPorts = [ 9100 ];
|
||||
extraCommands = ''
|
||||
iptables -A INPUT -p tcp -m tcp --source 192.168.10.175/32 --dport 9100 -j ACCEPT
|
||||
iptables -A INPUT -p tcp -m tcp --dport 9100 -j DROP
|
||||
'';
|
||||
};
|
||||
|
||||
services.promtail = {
|
||||
|
||||
Reference in New Issue
Block a user