From 96eb5785037c501ac5f0c4b473a6819e44a9d016 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Wed, 12 Jul 2017 18:11:30 -0500 Subject: Use Raptor boot script with lockdown support --- utils/pb-console | 116 ++++++------------------------------------------------- 1 file changed, 12 insertions(+), 104 deletions(-) diff --git a/utils/pb-console b/utils/pb-console index 282fca1..924e1c3 100644 --- a/utils/pb-console +++ b/utils/pb-console @@ -3,91 +3,8 @@ # Petitboot utility script for running a petitboot UI program # on a console tty. # - -ui=petitboot-nc -shell=sh -getty=/sbin/getty -use_getty=0 -detach=0 -pb_config=pb-config - -usage() { - cat >&2 < /proc/sys/kernel/printk +clear -while : -do - $ui $verbose_opt - reset - echo "Exiting petitboot. Type 'exit' to return." - echo "You may run 'pb-sos' to gather diagnostic data" - $shell -done +if [ -e /etc/pb-lockdown ]; then + echo "Failed to launch petitboot, rebooting!" + echo 1 > /proc/sys/kernel/sysrq + echo b > /proc/sysrq-trigger +else + echo "Failed to launch petitboot, dropping to a shell" + exec sh +fi -- cgit v1.1