mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Use common replication wait timeout of 5min
Instead of multiple timeout values all over the code base, all replication waits now use a common timeout value from api.env of 5 minutes. Waiting for HTTP/replica principal takes 90 to 120 seconds, so 5 minutes seem like a sufficient value for slow setups. Fixes: https://pagure.io/freeipa/issue/7595 Signed-off-by: Christian Heimes <cheimes@redhat.com> Reviewed-By: Fraser Tweedale <ftweedal@redhat.com>
This commit is contained in:
@@ -408,13 +408,16 @@ class KrbInstance(service.Service):
|
||||
def _wait_for_replica_kdc_entry(self):
|
||||
master_dn = self.api.Object.server.get_dn(self.fqdn)
|
||||
kdc_dn = DN(('cn', 'KDC'), master_dn)
|
||||
|
||||
ldap_uri = 'ldap://{}'.format(self.master_fqdn)
|
||||
|
||||
ldap_uri = ipaldap.get_ldap_uri(self.master_fqdn)
|
||||
with ipaldap.LDAPClient(
|
||||
ldap_uri, cacert=paths.IPA_CA_CRT) as remote_ldap:
|
||||
ldap_uri, cacert=paths.IPA_CA_CRT, start_tls=True
|
||||
) as remote_ldap:
|
||||
remote_ldap.gssapi_bind()
|
||||
replication.wait_for_entry(remote_ldap, kdc_dn, timeout=60)
|
||||
replication.wait_for_entry(
|
||||
remote_ldap,
|
||||
kdc_dn,
|
||||
timeout=api.env.replication_wait_timeout
|
||||
)
|
||||
|
||||
def _call_certmonger(self, certmonger_ca='IPA'):
|
||||
subject = str(DN(('cn', self.fqdn), self.subject_base))
|
||||
|
||||
Reference in New Issue
Block a user