From 4527be94c1142097290ebcdb2e18eac982faee28 Mon Sep 17 00:00:00 2001 From: "Sergey V. Yudin" Date: Tue, 4 Aug 2015 13:21:16 +0000 Subject: [PATCH] Make shell login in fuel-menu really interactive Enables job control in a shell by making use of the "screen" utility Closes-Bug: #1469137 Change-Id: I3f14dc214286e5a7dfcd9dff9dd004bef8414b2f --- fuelmenu/fuelmenu/modules/shell.py | 5 ++++- specs/nailgun.spec | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/fuelmenu/fuelmenu/modules/shell.py b/fuelmenu/fuelmenu/modules/shell.py index bef743bf72..91f141c58a 100644 --- a/fuelmenu/fuelmenu/modules/shell.py +++ b/fuelmenu/fuelmenu/modules/shell.py @@ -44,7 +44,10 @@ class shell(): self.parent.mainloop.screen.stop() message = "Type exit to return to the main UI." - subprocess.call("clear ; echo '%s';echo;bash -i" % message, shell=True) + subprocess.call( + "screen bash -c 'clear; echo %s ; echo; bash -i'" % message, + shell=True + ) self.parent.mainloop.screen.start() def refresh(self): diff --git a/specs/nailgun.spec b/specs/nailgun.spec index 76f2505cfa..f0f7e01649 100644 --- a/specs/nailgun.spec +++ b/specs/nailgun.spec @@ -226,6 +226,7 @@ Requires: python-netifaces Requires: python-urwid >= 1.1.0 Requires: PyYAML Requires: python-ordereddict +Requires: screen %description -n fuelmenu Summary: Console utility for pre-configuration of Fuel server