Change cli bool flag and fix ldap connection.

This commit is contained in:
sfigato 2019-04-28 12:26:20 +02:00
parent 543416368b
commit b0f312284d
Signed by: blallo
GPG Key ID: 0CBE577C9B72DC3F

View File

@ -90,7 +90,7 @@ def _validate_port(ctx, param, value):
help="Connect to the LDAP server using TLSv1.2. Defaults to True.",
)
@click.option(
"--ldap-tls-validate",
"--ldap-tls-do-not-validate",
"ldap_tls_validate",
is_flag=True,
default=True,
@ -193,6 +193,8 @@ def prepare_config_from_cli(
):
_core = {"listen": {"host": host, "port": port}}
_ldap = {
"host": ldap_host,
"port": ldap_port,
"encryption": "TLSv1.2" if ldap_crypt else None,
"validate": ldap_tls_validate,
"ca_certs": ldap_tls_ca,