From caf40e76cdca806be1849f70a81363289a96d454 Mon Sep 17 00:00:00 2001 From: Ana Krivokapic Date: Wed, 5 Jun 2013 15:52:47 +0200 Subject: Improve handling of options in ipa-client-install Improve handling of command line options related to forced client re-enrollment in ipa-client-install: * Make --keytab and --principal options mutually exclusive. * Warn that using --force-join together with --keytab provides no additional functionality. https://fedorahosted.org/freeipa/ticket/3686 --- ipa-client/ipa-install/ipa-client-install | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'ipa-client') diff --git a/ipa-client/ipa-install/ipa-client-install b/ipa-client/ipa-install/ipa-client-install index e86564dd..a5ba46cf 100755 --- a/ipa-client/ipa-install/ipa-client-install +++ b/ipa-client/ipa-install/ipa-client-install @@ -1844,6 +1844,15 @@ def install(options, env, fstore, statestore): "nss_ldap or nss-pam-ldapd") return CLIENT_INSTALL_ERROR + if options.keytab and options.principal: + root_logger.error("Options 'principal' and 'keytab' cannot be used " + "together.") + return CLIENT_INSTALL_ERROR + + if options.keytab and options.force_join: + root_logger.warning("Option 'force-join' has no additional effect " + "when used with together with option 'keytab'.") + # Create the discovery instance ds = ipadiscovery.IPADiscovery() -- cgit