mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
ipa-replica-install: password and admin-password options mutually exclusive
Currently it is possible to run ipa-replica-install in one step, and provide --password and --admin-password simultaneously. This is confusing as --password is intended for one-time pwd when the ipa-replica-install command is delegated to a user who doesn't know the admin password. The fix makes --password and --admin-password options mutually exclusive. Fixes https://pagure.io/freeipa/issue/6353 Reviewed-By: Christian Heimes <cheimes@redhat.com>
This commit is contained in:
parent
55c0a93271
commit
23306a28c9
@ -771,6 +771,10 @@ def promote_check(installer):
|
|||||||
|
|
||||||
client_fstore = sysrestore.FileStore(paths.IPA_CLIENT_SYSRESTORE)
|
client_fstore = sysrestore.FileStore(paths.IPA_CLIENT_SYSRESTORE)
|
||||||
if not client_fstore.has_files():
|
if not client_fstore.has_files():
|
||||||
|
# One-step replica installation
|
||||||
|
if options.password and options.admin_password:
|
||||||
|
raise ScriptError("--password and --admin-password options are "
|
||||||
|
"mutually exclusive")
|
||||||
ensure_enrolled(installer)
|
ensure_enrolled(installer)
|
||||||
else:
|
else:
|
||||||
if (options.domain_name or options.server or options.realm_name or
|
if (options.domain_name or options.server or options.realm_name or
|
||||||
|
Loading…
Reference in New Issue
Block a user