mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Improve output when options are not found in non-interactive client install
We should still give some feedback when things go wrong when in non-interactive mode. ticket 828
This commit is contained in:
@@ -542,6 +542,7 @@ def main():
|
|||||||
if options.domain:
|
if options.domain:
|
||||||
cli_domain = options.domain
|
cli_domain = options.domain
|
||||||
elif options.unattended:
|
elif options.unattended:
|
||||||
|
print >>sys.stderr, "Unable to discover domain, not provided on command line"
|
||||||
return ret
|
return ret
|
||||||
else:
|
else:
|
||||||
print "DNS discovery failed to determine your DNS domain"
|
print "DNS discovery failed to determine your DNS domain"
|
||||||
@@ -561,6 +562,7 @@ def main():
|
|||||||
if options.server:
|
if options.server:
|
||||||
cli_server = options.server
|
cli_server = options.server
|
||||||
elif options.unattended:
|
elif options.unattended:
|
||||||
|
print >>sys.stderr, "Unable to find IPA Server to join"
|
||||||
return ret
|
return ret
|
||||||
else:
|
else:
|
||||||
print "DNS discovery failed to find the IPA Server"
|
print "DNS discovery failed to find the IPA Server"
|
||||||
@@ -654,7 +656,7 @@ def main():
|
|||||||
sys.stdout.flush()
|
sys.stdout.flush()
|
||||||
else:
|
else:
|
||||||
if sys.stdin.isatty():
|
if sys.stdin.isatty():
|
||||||
sys.exit("Password must be provided in non-interactive mode")
|
sys.exit("Password must be provided in non-interactive mode.\nThis can be done via echo password | ipa-client-install ... or\nwith the -w option.")
|
||||||
else:
|
else:
|
||||||
stdin = sys.stdin.readline()
|
stdin = sys.stdin.readline()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user