test: HUP Finit from inside container instead ...

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
Joachim Wiberg
2022-04-05 06:49:52 +02:00
parent 5002c74876
commit ef1bfb869f
2 changed files with 3 additions and 1 deletions
+2
View File
@@ -19,6 +19,8 @@ test_teardown()
say "Hi, this is /run et al"
texec sh -c "echo 'ROOT:/bin'; ls -l /bin/; echo 'ROOT:/sbin'; ls -l /sbin/; echo 'ROOT:/run'; ls -l /run/; echo 'ROOT:/run/finit/'; ls -l /run/finit/; echo 'ROOT:/dev'; ls -l /dev/; ps; ls -l /proc/1/fd/"
say "HUPing PID 1 ..."
texec sh -c "kill -HUP 1"
say "Test start $(date)"
+1 -1
View File
@@ -158,6 +158,7 @@ fi
finit_ppid=$!
echo "$finit_ppid" > "$TENV_ROOT"/running_test.pid
>&2 echo "Finit runs as PID $finit_ppid outside of container."
>&2 echo "Hint: Execute 'TENV_ROOT=$TENV_ROOT $TEST_DIR/tenv/enter.sh' to enter the test namespace"
log "$color_reset" 'Setup of test environment done' ''
@@ -170,5 +171,4 @@ fi
#tty=/dev/$(texec cat /sys/class/tty/console/active)
#texec cat "$tty" &
sleep 5
kill -HUP "$finit_pid"