mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
ipa-nis-manage enable: change service name from 'portmap' to 'rpcbind'
https://fedorahosted.org/freeipa/ticket/5857 Reviewed-By: Abhijeet Kasurde <akasurde@redhat.com> Reviewed-By: Martin Basti <mbasti@redhat.com>
This commit is contained in:
parent
865935739a
commit
bede6c282e
@ -144,19 +144,18 @@ def main():
|
|||||||
retval = 1
|
retval = 1
|
||||||
|
|
||||||
# Enable either the portmap or rpcbind service
|
# Enable either the portmap or rpcbind service
|
||||||
try:
|
portmap = services.knownservices.portmap
|
||||||
portmap = services.knownservices.portmap
|
rpcbind = services.knownservices.rpcbind
|
||||||
|
|
||||||
|
if portmap.is_installed():
|
||||||
portmap.enable()
|
portmap.enable()
|
||||||
servicemsg = portmap.service_name
|
servicemsg = portmap.service_name
|
||||||
except ipautil.CalledProcessError as cpe:
|
elif rpcbind.is_installed():
|
||||||
if cpe.returncode == 1:
|
rpcbind.enable()
|
||||||
try:
|
servicemsg = rpcbind.service_name
|
||||||
rpcbind = services.knownservices.rpcbind
|
else:
|
||||||
rpcbind.enable()
|
print("Unable to enable either %s or %s" % (portmap.service_name, rpcbind.service_name))
|
||||||
servicemsg = rpcbind.service_name
|
retval = 3
|
||||||
except ipautil.CalledProcessError as cpe:
|
|
||||||
print("Unable to enable either %s or %s" % (portmap.service_name, rpcbind.service_name))
|
|
||||||
retval = 3
|
|
||||||
|
|
||||||
# The cn=config entry for the plugin may already exist but it
|
# The cn=config entry for the plugin may already exist but it
|
||||||
# could be turned off, handle both cases.
|
# could be turned off, handle both cases.
|
||||||
|
Loading…
Reference in New Issue
Block a user