mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-01 19:33:03 +00:00
unbound service: extend isLocalAddress to handle ipv6
This commit is contained in:
parent
bf538515b7
commit
22d6c97855
@ -12,7 +12,7 @@ let
|
||||
|
||||
interfaces = concatMapStrings (x: " interface: ${x}\n") cfg.interfaces;
|
||||
|
||||
isLocalAddress = x: substring 0 9 x == "127.0.0.1";
|
||||
isLocalAddress = x: substring 0 3 x == "::1" || substring 0 9 x == "127.0.0.1";
|
||||
|
||||
forward =
|
||||
optionalString (any isLocalAddress cfg.forwardAddresses) ''
|
||||
|
Loading…
Reference in New Issue
Block a user