diff options
author | Joachim Fasting <joachifm@fastmail.fm> | 2016-09-16 09:47:36 +0200 |
---|---|---|
committer | Joachim Fasting <joachifm@fastmail.fm> | 2016-09-16 09:47:36 +0200 |
commit | 22d6c97855b99e770855474f394cd4a3192d98d9 (patch) | |
tree | 756697e3d17bbb2e99c1f169041ef5e5e4daf657 /nixos/modules/services/networking | |
parent | bf538515b7d668f9522b1db7d07ffe087f9d8a7f (diff) | |
download | nixlib-22d6c97855b99e770855474f394cd4a3192d98d9.tar nixlib-22d6c97855b99e770855474f394cd4a3192d98d9.tar.gz nixlib-22d6c97855b99e770855474f394cd4a3192d98d9.tar.bz2 nixlib-22d6c97855b99e770855474f394cd4a3192d98d9.tar.lz nixlib-22d6c97855b99e770855474f394cd4a3192d98d9.tar.xz nixlib-22d6c97855b99e770855474f394cd4a3192d98d9.tar.zst nixlib-22d6c97855b99e770855474f394cd4a3192d98d9.zip |
unbound service: extend isLocalAddress to handle ipv6
Diffstat (limited to 'nixos/modules/services/networking')
-rw-r--r-- | nixos/modules/services/networking/unbound.nix | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nixos/modules/services/networking/unbound.nix b/nixos/modules/services/networking/unbound.nix index 828b8e175569..6375ebee3209 100644 --- a/nixos/modules/services/networking/unbound.nix +++ b/nixos/modules/services/networking/unbound.nix @@ -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) '' |