From d68613194b4a26239ebb689d7270cf6c2035afbd Mon Sep 17 00:00:00 2001 From: Jan Cholasta Date: Mon, 14 Dec 2015 13:30:33 +0100 Subject: [PATCH] replica promotion: notify user about ignoring client enrollment options When IPA client is already installed, notify the user that the enrollment options are ignored in ipa-replica-install. https://fedorahosted.org/freeipa/ticket/5530 Reviewed-By: Tomas Babej --- ipaserver/install/server/replicainstall.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ipaserver/install/server/replicainstall.py b/ipaserver/install/server/replicainstall.py index 1d5b528c8..d62edd17d 100644 --- a/ipaserver/install/server/replicainstall.py +++ b/ipaserver/install/server/replicainstall.py @@ -883,6 +883,12 @@ def promote_check(installer): client_fstore = sysrestore.FileStore(paths.IPA_CLIENT_SYSRESTORE) if not client_fstore.has_files(): ensure_enrolled(installer) + else: + if (options.domain_name or options.server or options.realm_name or + options.host_name or options.password or options.keytab): + print("IPA client is already configured on this system, ignoring " + "the --domain, --server, --realm, --hostname, --password " + "and --keytab options.") sstore = sysrestore.StateFile(paths.SYSRESTORE)