On Wed, 2012-06-13 at 15:18 -0400, David Cantrell wrote: > This looks ok with one style comment. > > On Tue, Jun 12, 2012 at 03:21:50PM -0700, Jesse Keating wrote: > > Additionally, when RUNKS is provided, default to the "cmdline" > > interface. On s390x if any other more advanced interface is used, the > > console will get garbled. Other interface options provided in the > > kickstart file will override this default. > > --- > > anaconda | 31 ++++++++++++++----------------- > > 1 file changed, 14 insertions(+), 17 deletions(-) > > > > diff --git a/anaconda b/anaconda > > index 46a8748..e900b91 100755 > > --- a/anaconda > > +++ b/anaconda > > @@ -594,16 +594,7 @@ def setupDisplay(anaconda, opts): > > > > def prompt_for_ssh(): > > # Do some work here to get the ip addr / hostname to pass > > - # to the user. This code won't make use of /tmp/updates/ contents as > > - # it hasn't been loaded yet. > > - import logging > > - from pyanaconda import anaconda_log > > - anaconda_log.init() > > - anaconda_log.logger.setupVirtio() > > - > > - log = logging.getLogger("anaconda") > > - stdoutLog = logging.getLogger("anaconda.stdout") > > - > > + # to the user. > > from pyanaconda import network > > from pyanaconda import isys > > import socket > > @@ -660,13 +651,6 @@ def prompt_for_ssh(): > > > > > > if __name__ == "__main__": > > - # see if we're on s390x and if we've got an ssh connection > > - uname = os.uname() > > - if uname[4] == 's390x': > > - if not 'SSH_CONNECTION' in os.environ: > > - prompt_for_ssh() > > - sys.exit(0) > > - > > setupPythonPath() > > > > # Allow a file to be loaded as early as possible > > @@ -697,6 +681,19 @@ if __name__ == "__main__": > > stdoutLog.error("anaconda must be run as root.") > > sys.exit(0) > > > > + # see if we're on s390x and if we've got an ssh connection > > + uname = os.uname() > > + if uname[4] == 's390x': > > + if 'SSH_CONNECTION' in os.environ or "RUNKS" in flags.cmdline: > > + pass > > + else: > > + prompt_for_ssh() > > + sys.exit(0) > > Any reason to not do: > > if 'SSH_CONNECTION' not in os.environ and "RUNKS" not in flags.cmdline: > prompt_for_ssh() > sys.exit(0) What about: if not ('SSH_CONNECTION' in os.environ or 'RUNKS' in flags.cmdline): prompt_for_ssh() sys.exit(0) (note also the single quotes enclosing both strings) -- Vratislav Podzimek Anaconda Rider | Red Hat, Inc. | Brno - Czech Republic _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list