[PATCH 1/3] Be more specific about what was set in the kickstart (#963970)
Vratislav Podzimek
vpodzime at redhat.com
Tue May 28 13:15:56 UTC 2013
The root account may be e.g. locked in the kickstart.
Signed-off-by: Vratislav Podzimek <vpodzime at redhat.com>
---
pyanaconda/ui/gui/spokes/password.py | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/pyanaconda/ui/gui/spokes/password.py b/pyanaconda/ui/gui/spokes/password.py
index ff029ea..7cd6e49 100644
--- a/pyanaconda/ui/gui/spokes/password.py
+++ b/pyanaconda/ui/gui/spokes/password.py
@@ -19,6 +19,7 @@
# Red Hat Author(s): Jesse Keating <jkeating at redhat.com>
#
+# pylint: disable-msg=E0611
from gi.repository import Gtk
from pyanaconda.i18n import _, N_
@@ -58,7 +59,7 @@ class PasswordSpoke(FirstbootSpokeMixIn, NormalSpoke):
self.confirm = self.builder.get_object("confirm")
self._kickstarted = self.data.rootpw.seen
- if self._kickstarted:
+ if self._kickstarted and self.rootpw.password:
self.pw.set_placeholder_text(_("The password was set by kickstart."))
self.confirm.set_placeholder_text(_("The password was set by kickstart."))
@@ -79,7 +80,10 @@ class PasswordSpoke(FirstbootSpokeMixIn, NormalSpoke):
if self._error:
return _("Error setting root password")
elif self._kickstarted:
- return _("Root password was set by kickstart")
+ if self.data.rootpw.password:
+ return _("Root password was set by kickstart")
+ elif self.data.rootpw.lock:
+ return _("Root account was disabled by kickstart")
elif self.data.rootpw.password:
return _("Root password is set")
elif self.data.rootpw.lock:
--
1.7.11.7
More information about the anaconda-patches
mailing list