at 25.11-pre 1.3 kB view raw
1import ./make-test-python.nix ( 2 { lib, ... }: 3 { 4 name = "tinydns"; 5 meta = { 6 maintainers = with lib.maintainers; [ basvandijk ]; 7 }; 8 nodes = { 9 nameserver = 10 { config, lib, ... }: 11 let 12 ip = (lib.head config.networking.interfaces.eth1.ipv4.addresses).address; 13 in 14 { 15 networking.nameservers = [ ip ]; 16 services.tinydns = { 17 enable = true; 18 inherit ip; 19 data = '' 20 .foo.bar:${ip} 21 +.bla.foo.bar:1.2.3.4:300 22 ''; 23 }; 24 }; 25 }; 26 testScript = '' 27 nameserver.start() 28 nameserver.wait_for_unit("tinydns.service") 29 30 # We query tinydns a few times to trigger the bug: 31 # 32 # nameserver # [ 6.105872] mmap: tinydns (842): VmData 331776 exceed data ulimit 300000. Update limits or use boot option ignore_rlimit_data. 33 # 34 # which was reported in https://github.com/NixOS/nixpkgs/issues/119066. 35 # Without the patch <nixpkgs/pkgs/tools/networking/djbdns/softlimit.patch> 36 # it fails on the 10th iteration. 37 nameserver.succeed( 38 """ 39 for i in {1..100}; do 40 host bla.foo.bar 192.168.1.1 | grep '1\.2\.3\.4' 41 done 42 """ 43 ) 44 ''; 45 } 46)