From 20c2f32d4ed2419103dc0d95c4aa13df5f98c3dc Mon Sep 17 00:00:00 2001 From: ibizaman Date: Sat, 14 Oct 2023 21:17:59 -0700 Subject: [PATCH] use options for ldap ports --- modules/ldap.nix | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/modules/ldap.nix b/modules/ldap.nix index 4c02576..331b15f 100644 --- a/modules/ldap.nix +++ b/modules/ldap.nix @@ -27,6 +27,18 @@ in example = "mydomain.com"; }; + ladpPort = lib.mkOption { + type = lib.types.port; + description = "Port on which the server listens for the LDAP protocol."; + default = 3890; + }; + + httpPort = lib.mkOption { + type = lib.types.port; + description = "Port on which the web UI is exposed."; + default = 17170; + }; + sopsFile = lib.mkOption { type = lib.types.path; description = "Sops file location"; @@ -98,10 +110,10 @@ in settings = { http_url = "https://${fqdn}"; http_host = "127.0.0.1"; - http_port = 17170; + http_port = cfg.httpPort; ldap_host = "127.0.0.1"; - ldap_port = 3890; + ldap_port = cfg.ladpPort; ldap_base_dn = cfg.dcdomain;