mirror of
https://github.com/troglobit/finit.git
synced 2026-10-01 05:22:48 +07:00
test: Use STDOUT of parent process instead of a pipe as tty for finit
Signed-off-by: Jacques de Laval <jacques@de-laval.se>
This commit is contained in:
@@ -44,6 +44,6 @@ fi
|
||||
mkdir -p "$FINIT_RCSD"
|
||||
|
||||
tty=/dev/$(cat /sys/class/tty/console/active)
|
||||
mkfifo "$tty"
|
||||
ln -fs /shared/pts "$tty"
|
||||
|
||||
exec "$@"
|
||||
|
||||
@@ -138,7 +138,3 @@ echo "$finit_ppid" > "$TENV_ROOT"/running_test.pid
|
||||
log "$color_reset" 'Setup of test environment done' ''
|
||||
|
||||
finit_pid=$(retry "pgrep -P $finit_ppid")
|
||||
|
||||
tty=/dev/$(texec cat /sys/class/tty/console/active)
|
||||
texec cat "$tty" &
|
||||
sleep 1
|
||||
|
||||
@@ -38,6 +38,7 @@ binaries = $(DEST)/bin/cat \
|
||||
$(DEST)/bin/env \
|
||||
$(DEST)/bin/find \
|
||||
$(DEST)/bin/kill \
|
||||
$(DEST)/bin/ln \
|
||||
$(DEST)/bin/ls \
|
||||
$(DEST)/bin/mkdir \
|
||||
$(DEST)/bin/mkfifo \
|
||||
@@ -57,6 +58,7 @@ dirs = $(DEST)/bin \
|
||||
$(DEST)/etc \
|
||||
$(DEST)/proc \
|
||||
$(DEST)/sbin \
|
||||
$(DEST)/shared \
|
||||
$(DEST)/sys \
|
||||
$(DEST)/test_assets \
|
||||
$(DEST)/tmp
|
||||
|
||||
+4
-1
@@ -45,4 +45,7 @@ exec "$unshare" \
|
||||
--mount \
|
||||
--mount-proc \
|
||||
--uts --ipc --net \
|
||||
"$chroot" "$TENV_ROOT" /bin/chrootsetup.sh "$@"
|
||||
sh -c "
|
||||
ln -fs /proc/1/fd/1 $TENV_ROOT/shared/pts;
|
||||
exec $chroot $TENV_ROOT /bin/chrootsetup.sh $*
|
||||
"
|
||||
|
||||
Reference in New Issue
Block a user