summaryrefslogtreecommitdiffstats
path: root/install/tools
diff options
context:
space:
mode:
authorSimo Sorce <simo@redhat.com>2015-10-23 11:21:01 -0400
committerMartin Basti <mbasti@redhat.com>2015-10-27 17:42:30 +0100
commit53294aa7a7db7eff527455fc35283306b37fc777 (patch)
tree39afb46be374c078d4ad65e037dd6abceb759b26 /install/tools
parentc38516eab7b82f3ba7334cdea7a422a070048b59 (diff)
downloadfreeipa-53294aa7a7db7eff527455fc35283306b37fc777.tar.gz
freeipa-53294aa7a7db7eff527455fc35283306b37fc777.tar.xz
freeipa-53294aa7a7db7eff527455fc35283306b37fc777.zip
Check early if a CA is already installed locally
There is no reason to proceed if a CA is already installed, and the check does not involve a lot of setup, so do it early on. Ticket: https://fedorahosted.org/freeipa/ticket/5397 Signed-off-by: Simo Sorce <simo@redhat.com> Reviewed-By: Martin Basti <mbasti@redhat.com>
Diffstat (limited to 'install/tools')
-rwxr-xr-xinstall/tools/ipa-ca-install3
1 files changed, 3 insertions, 0 deletions
diff --git a/install/tools/ipa-ca-install b/install/tools/ipa-ca-install
index 7f4c62176..4c778d950 100755
--- a/install/tools/ipa-ca-install
+++ b/install/tools/ipa-ca-install
@@ -231,6 +231,9 @@ def main():
if not dsinstance.DsInstance().is_configured():
sys.exit("IPA server is not configured on this system.\n")
+ if cainstance.is_ca_installed_locally():
+ sys.exit("CA is already installed on this host.")
+
standard_logging_setup(paths.IPASERVER_CA_INSTALL_LOG, debug=options.debug)
root_logger.debug("%s was invoked with options: %s,%s",
sys.argv[0], safe_options, filename)