Several fixes to restconf internal and vagrants tests

This commit is contained in:
Olof hagsand 2021-05-24 11:31:00 +02:00
parent 603f70e51f
commit ae02d02d63
6 changed files with 47 additions and 7 deletions

View file

@ -28,7 +28,9 @@ fi
# Fcgi restconf requires /www-data directory for fcgi socket
if [ ${with_restconf} = fcgi ]; then
sudo mkdir /www-data
if [ ! -d /www-data ]; then
sudo mkdir /www-data
fi
sudo chown $wwwuser /www-data
sudo chgrp $wwwuser /www-data
fi

View file

@ -35,6 +35,13 @@ linuxrelease()
break
fi
done
# Special cases
if [ "$release" = "unknown" ]; then
if [ -n "$(echo "$box" | grep -io "bionic")" ]; then
release=ubuntu
break;
fi
fi
echo "$release"
}
@ -53,6 +60,11 @@ wwwuser=www-data
release=$(linuxrelease $box)
echo "release:$release"
if [ "$release" = unknown ]; then
echo "$box not recognized"
exit 255
fi
test -d $dir || mkdir -p $dir
# Write a vagrant file