summary refs log tree commit diff
path: root/nixos/tests/openldap.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixos/tests/openldap.nix')
-rw-r--r--nixos/tests/openldap.nix10
1 files changed, 5 insertions, 5 deletions
diff --git a/nixos/tests/openldap.nix b/nixos/tests/openldap.nix
index 33b7b7f6608..0c40073735e 100644
--- a/nixos/tests/openldap.nix
+++ b/nixos/tests/openldap.nix
@@ -1,5 +1,5 @@
 { pkgs, system ? builtins.currentSystem, ... }: let
-  declarativeContents = ''
+  dbContents = ''
     dn: dc=example
     objectClass: domain
     dc: example
@@ -22,7 +22,6 @@ in {
 
     machine = { pkgs, ... }: {
       services.openldap = {
-        inherit declarativeContents;
         enable = true;
         defaultSchemas = null;
         dataDir = null;
@@ -49,6 +48,7 @@ in {
             };
           };
         };
+        declarativeContents."dc=example" = dbContents;
       };
     };
   };
@@ -60,11 +60,11 @@ in {
 
     machine = { pkgs, ... }: {
       services.openldap = {
-        inherit declarativeContents;
         enable = true;
         suffix = "dc=example";
         rootdn = "cn=root,dc=example";
         rootpw = "notapassword";
+        declarativeContents = dbContents;
       };
     };
   };
@@ -85,7 +85,7 @@ in {
     };
 
     testScript = let
-      contents = pkgs.writeText "data.ldif" declarativeContents;
+      contents = pkgs.writeText "data.ldif" dbContents;
       config = pkgs.writeText "config.ldif" ''
         dn: cn=config
         cn: config
@@ -129,7 +129,6 @@ in {
 
     machine = { pkgs, ... }: {
       services.openldap = {
-        inherit declarativeContents;
         enable = true;
         suffix = "dc=example";
         rootdn = "cn=root,dc=example";
@@ -140,6 +139,7 @@ in {
         extraDatabaseConfig = ''
           # No-op
         '';
+        declarativeContents = dbContents;
       };
     };
   };