summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
980f66f)
If dash is used as /bin/sh then $RANDOM isn't set.
Running all the runit.sh scripts using zsh as well addresses this issue,
also check for $RANDOM in framework.sh so we exit before running into
obscure error messages.
COMMON_PORT=0
STATUS_PORT=0
COMMON_PORT=0
STATUS_PORT=0
+# $RANDOM is not set in dash
+if [ -z "$RANDOM" ] ; then
+ echo "Variable \$RANDOM not set, can not choose random port. Exiting.">&2
+ bailout
+fi
+
while [ $COMMON_PORT -lt 1024 ] || [ $STATUS_PORT -lt 1024 ] ; do
COMMON_PORT=$RANDOM
STATUS_PORT=$RANDOM
while [ $COMMON_PORT -lt 1024 ] || [ $STATUS_PORT -lt 1024 ] ; do
COMMON_PORT=$RANDOM
STATUS_PORT=$RANDOM
for i in grub lilo ; do
PARENT=$$ $i/runit.sh
for i in grub lilo ; do
PARENT=$$ $i/runit.sh