Merge pull request #182394 from NixOS/revert-182080-openldap-sysconfdir

Revert "openldap: load client config from /etc, not the nix store"
This commit is contained in:
Martin Weinelt 2022-07-22 00:29:58 +02:00 committed by GitHub
commit 24e8a4993b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 13 deletions

View file

@ -13,17 +13,10 @@ let
objectClass: organizationalUnit
ou: users
'';
ldapClientConfig = {
enable = true;
loginPam = false;
nsswitch = false;
server = "ldap://";
base = "dc=example";
};
testScript = ''
machine.wait_for_unit("openldap.service")
machine.succeed(
'ldapsearch -LLL -D "cn=root,dc=example" -w notapassword',
'ldapsearch -LLL -D "cn=root,dc=example" -w notapassword -b "dc=example"',
)
'';
in {
@ -64,7 +57,6 @@ in {
};
declarativeContents."dc=example" = dbContents;
};
users.ldap = ldapClientConfig;
};
}) { inherit pkgs system; };
@ -84,7 +76,6 @@ in {
rootpw = "notapassword";
declarativeContents."dc=example" = dbContents;
};
users.ldap = ldapClientConfig;
};
}) { inherit system pkgs; };
@ -97,7 +88,6 @@ in {
enable = true;
configDir = "/var/db/slapd.d";
};
users.ldap = ldapClientConfig;
};
testScript = let

View file

@ -97,7 +97,7 @@ stdenv.mkDerivation rec {
"CC=${stdenv.cc.targetPrefix}cc"
"STRIP=" # Disable install stripping as it breaks cross-compiling. We strip binaries anyway in fixupPhase.
"prefix=${placeholder "out"}"
"sysconfdir=/etc"
"sysconfdir=${placeholder "out"}/etc"
"systemdsystemunitdir=${placeholder "out"}/lib/systemd/system"
# contrib modules require these
"moduledir=${placeholder "out"}/lib/modules"
@ -134,7 +134,6 @@ stdenv.mkDerivation rec {
installFlags = [
"prefix=${placeholder "out"}"
"sysconfdir=${placeholder "out"}/etc"
"moduledir=${placeholder "out"}/lib/modules"
"INSTALL=install"
];