summaryrefslogtreecommitdiffstats
path: root/ipaserver/install/opendnssecinstance.py
diff options
context:
space:
mode:
authorMartin Basti <mbasti@redhat.com>2015-01-27 11:04:03 +0100
committerMartin Kosek <mkosek@redhat.com>2015-02-18 10:05:45 +0100
commitc3edfa2d8cee8f318837fb31680b495035a8bd2d (patch)
tree28288d817156bd4a27af122e1803b7a49c274e1d /ipaserver/install/opendnssecinstance.py
parent76d401bb882283b039de2ceee8300d0c838db473 (diff)
downloadfreeipa-c3edfa2d8cee8f318837fb31680b495035a8bd2d.tar.gz
freeipa-c3edfa2d8cee8f318837fb31680b495035a8bd2d.tar.xz
freeipa-c3edfa2d8cee8f318837fb31680b495035a8bd2d.zip
Fix restoring services status during uninstall
Services hasn't been restored correctly, which causes disabling already disabled services, or some service did not start. This patch fix these issues. Ticket: https://fedorahosted.org/freeipa/ticket/4869 Reviewed-By: David Kupka <dkupka@redhat.com>
Diffstat (limited to 'ipaserver/install/opendnssecinstance.py')
-rw-r--r--ipaserver/install/opendnssecinstance.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/ipaserver/install/opendnssecinstance.py b/ipaserver/install/opendnssecinstance.py
index 0d2fb009e..869cf8ffe 100644
--- a/ipaserver/install/opendnssecinstance.py
+++ b/ipaserver/install/opendnssecinstance.py
@@ -149,7 +149,6 @@ class OpenDNSSECInstance(service.Service):
self.suffix, self.extra_config)
except errors.DuplicateEntry:
root_logger.error("DNSSEC service already exists")
- self.enable()
def __setup_conf_files(self):
if not self.fstore.has_file(paths.OPENDNSSEC_CONF_FILE):
@@ -292,8 +291,9 @@ class OpenDNSSECInstance(service.Service):
root_logger.debug(error)
pass
- if enabled is not None and not enabled:
- self.disable()
+ # disabled by default, by ldap_enable()
+ if enabled:
+ self.enable()
- if running is not None and running:
- self.start()
+ if running:
+ self.restart()