From 98cf79175e8bd2765899da6593856fdd9fd4bd36 Mon Sep 17 00:00:00 2001 From: Mathieu Trudel-Lapierre Date: Tue, 30 Aug 2016 22:20:00 -0400 Subject: [PATCH] More shuffling for gettys: reinstate the wrapper for VTs, make sure we display the issue file. --- bin/console-conf-wait | 0 bin/console-conf-wrapper | 8 ++++++++ debian/changelog | 10 ++++++++-- debian/console-conf.console-conf@.service | 2 +- debian/console-conf.install | 1 + 5 files changed, 18 insertions(+), 3 deletions(-) mode change 100755 => 100644 bin/console-conf-wait create mode 100755 bin/console-conf-wrapper diff --git a/bin/console-conf-wait b/bin/console-conf-wait old mode 100755 new mode 100644 diff --git a/bin/console-conf-wrapper b/bin/console-conf-wrapper new file mode 100755 index 00000000..88b37418 --- /dev/null +++ b/bin/console-conf-wrapper @@ -0,0 +1,8 @@ +#!/bin/sh +set -e + +trap true HUP INT QUIT TSTP + +cat /usr/share/subiquity/console-conf-wait +read REPLY +exec console-conf "$@" diff --git a/debian/changelog b/debian/changelog index 62668443..9c80f925 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,8 @@ subiquity (0.0.13) UNRELEASED; urgency=medium [ Mathieu Trudel-Lapierre ] - * bin/console-conf-wait: replace console-conf-wrapper with an issue file - that agetty can show on screen while waiting for user input. + * bin/console-conf-wait: add an issue file that agetty can show on screen + while waiting for user input. This is used directly for serial. * debian/console-conf.*.service: configure agetty to wait for user input before running our login program (console-conf), and display our issue file in the meantime. Always clear the screen, so that the issue text @@ -10,6 +10,12 @@ subiquity (0.0.13) UNRELEASED; urgency=medium * debian/console-conf.serial-console-conf@.service: pass --serial as an explicit login-program option to avoid it being seen as a parameter to agetty. + * debian/console-conf-wrapper: display the contents of our issue file + instead of a hard-coded string. + + [ Steve Langasek ] + * debian/console-conf-wrapper: trap various signals in our shell script, + as they should be in console-conf itself. [ Michael Hudson-Doyle ] * Prevent C-c, C-\ and C-x from exiting console-conf. diff --git a/debian/console-conf.console-conf@.service b/debian/console-conf.console-conf@.service index 53f5d324..29b16b84 100644 --- a/debian/console-conf.console-conf@.service +++ b/debian/console-conf.console-conf@.service @@ -11,7 +11,7 @@ ConditionPathExists=!/var/lib/console-conf/complete [Service] Environment=PYTHONPATH=/usr/share/subiquity ExecStartPre=/bin/systemctl stop getty@%I -ExecStart=-/sbin/agetty -n --keep-baud -f /usr/share/subiquity/console-conf-wait -w -l /usr/bin/console-conf %I $TERM +ExecStart=-/sbin/agetty -n --noclear -l /usr/share/subiquity/console-conf-wrapper %I $TERM ExecStop=/bin/systemctl start getty@%I #ExecStopPost=/bin/echo "Post stop, starting getty@%I" #ExecStopPost=/bin/systemctl start getty@%I diff --git a/debian/console-conf.install b/debian/console-conf.install index 5bbc6070..fb8829f4 100644 --- a/debian/console-conf.install +++ b/debian/console-conf.install @@ -1,3 +1,4 @@ bin/console-conf-tui usr/share/subiquity bin/console-conf-wait usr/share/subiquity +bin/console-conf-wrapper usr/share/subiquity usr/share/subiquity/console_conf