1
0
angie-conv-image/image-entry.d/90-angie-config-test.sh

26 lines
447 B
Bash
Raw Normal View History

2024-07-11 13:37:35 +03:00
#!/bin/sh
set -f
. /image-entry.d/00-common.envsh
## merely debug test
log_always 'test Angie configuration:'
log_always '========================='
angie -t
r=$?
log_always '========================='
## cleanup after test
2024-07-15 16:15:47 +03:00
rm -f "${volume_root}/angie.pid"
2024-07-11 13:37:35 +03:00
if [ $r = 0 ] ; then
log_always 'ready to run Angie'
else
log_always 'configuration test has failed, see above'
t=15
log_always "injecting delay for $t seconds"
sleep $t
fi
exit 0