Merge pull request #91514 from NinjaTrappeur/nin-fix-nsdconf
nixos/nsd: symlink conf file to /etc/nsd
This commit is contained in:
commit
b2655b6a34
@ -11,8 +11,6 @@ let
|
|||||||
|
|
||||||
# build nsd with the options needed for the given config
|
# build nsd with the options needed for the given config
|
||||||
nsdPkg = pkgs.nsd.override {
|
nsdPkg = pkgs.nsd.override {
|
||||||
configFile = "${configFile}/nsd.conf";
|
|
||||||
|
|
||||||
bind8Stats = cfg.bind8Stats;
|
bind8Stats = cfg.bind8Stats;
|
||||||
ipv6 = cfg.ipv6;
|
ipv6 = cfg.ipv6;
|
||||||
ratelimit = cfg.ratelimit.enable;
|
ratelimit = cfg.ratelimit.enable;
|
||||||
@ -897,7 +895,10 @@ in
|
|||||||
+ "want, please enable 'services.nsd.rootServer'.";
|
+ "want, please enable 'services.nsd.rootServer'.";
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = [ nsdPkg ];
|
environment = {
|
||||||
|
systemPackages = [ nsdPkg ];
|
||||||
|
etc."nsd/nsd.conf".source = "${configFile}/nsd.conf";
|
||||||
|
};
|
||||||
|
|
||||||
users.groups.${username}.gid = config.ids.gids.nsd;
|
users.groups.${username}.gid = config.ids.gids.nsd;
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ stdenv, fetchurl, libevent, openssl
|
{ stdenv, fetchurl, libevent, openssl, nixosTests
|
||||||
, bind8Stats ? false
|
, bind8Stats ? false
|
||||||
, checking ? false
|
, checking ? false
|
||||||
, ipv6 ? true
|
, ipv6 ? true
|
||||||
@ -11,7 +11,7 @@
|
|||||||
, rrtypes ? false
|
, rrtypes ? false
|
||||||
, zoneStats ? false
|
, zoneStats ? false
|
||||||
|
|
||||||
, configFile ? "etc/nsd/nsd.conf"
|
, configFile ? "/etc/nsd/nsd.conf"
|
||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
@ -52,6 +52,10 @@ stdenv.mkDerivation rec {
|
|||||||
sed 's@$(INSTALL_DATA) nsd.conf.sample $(DESTDIR)$(nsdconfigfile).sample@@g' -i Makefile.in
|
sed 's@$(INSTALL_DATA) nsd.conf.sample $(DESTDIR)$(nsdconfigfile).sample@@g' -i Makefile.in
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
passthru.tests = {
|
||||||
|
inherit (nixosTests) nsd;
|
||||||
|
};
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
homepage = "http://www.nlnetlabs.nl";
|
homepage = "http://www.nlnetlabs.nl";
|
||||||
description = "Authoritative only, high performance, simple and open source name server";
|
description = "Authoritative only, high performance, simple and open source name server";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user