mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2026-11-02 08:59:57 -06:00
Add pkey_only to the service_find calls in host del and disable
The pkey of services is krbprincipalname. The host plugin passes this full value to service_del and service_disable if the service hostname matches the requested host. This limits the amount of data and post-processing done when host_del and host_disable call service_find. It also saves a presence query for keytab in each service found. https://pagure.io/freeipa/issue/8787 Signed-off-by: Rob Crittenden <rcritten@redhat.com> Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com> Reviewed-By: Florence Blanc-Renaud <frenaud@redhat.com>
This commit is contained in:
1 parent
b3488b2131
commit
7e0626a922
1 file changed
+2
-2
@@ -808,7 +808,7 @@ class host_del(LDAPDelete):
|
||||
truncated = True
|
||||
while truncated:
|
||||
try:
|
||||
ret = api.Command['service_find'](fqdn)
|
||||
ret = api.Command['service_find'](fqdn, pkey_only=True)
|
||||
truncated = ret['truncated']
|
||||
services = ret['result']
|
||||
except errors.NotFound:
|
||||
@@ -1205,7 +1205,7 @@ class host_disable(LDAPQuery):
|
||||
truncated = True
|
||||
while truncated:
|
||||
try:
|
||||
ret = api.Command['service_find'](fqdn)
|
||||
ret = api.Command['service_find'](fqdn, pkey_only=True)
|
||||
truncated = ret['truncated']
|
||||
services = ret['result']
|
||||
except errors.NotFound:
|
||||
|
||||
Reference in new issue
Block a user