This commit is contained in:
Adam Warner 2017-05-05 22:24:40 +01:00
parent f270f7430c
commit 5cd2c77d98
No known key found for this signature in database
GPG key ID: 7C062498C7FA6E49

View file

@ -874,44 +874,11 @@ installPiholeWeb() {
echo ":::" echo ":::"
echo -n "::: Installing index.php..." echo -n "::: Installing index.php..."
if [ -d "/var/www/html/pihole" ]; then if [ -d "/var/www/html/pihole" ]; then
if [ -f "/var/www/html/pihole/index.php" ]; then if [[ ${CUSTOMBLOCKPAGE} == false ]]; then
if [[ ${CUSTOMBLOCKPAGE} == true ]]; then
echo " Existing index.php detected, not overwriting"
else
cp ${PI_HOLE_LOCAL_REPO}/advanced/index.php /var/www/html/pihole/ cp ${PI_HOLE_LOCAL_REPO}/advanced/index.php /var/www/html/pihole/
echo " done!"
fi
else
cp ${PI_HOLE_LOCAL_REPO}/advanced/index.php /var/www/html/pihole/
echo " done!"
fi
echo -n "::: Installing index.js..."
if [ -f "/var/www/html/pihole/index.js" ]; then
if [[ ${CUSTOMBLOCKPAGE} == true ]]; then
echo " Existing index.js detected, not overwriting"
else
cp ${PI_HOLE_LOCAL_REPO}/advanced/index.js /var/www/html/pihole/ cp ${PI_HOLE_LOCAL_REPO}/advanced/index.js /var/www/html/pihole/
echo " done!"
fi
else
cp ${PI_HOLE_LOCAL_REPO}/advanced/index.js /var/www/html/pihole/
echo " done!"
fi
echo -n "::: Installing blockingpage.css..."
if [ -f "/var/www/html/pihole/blockingpage.css" ]; then
if [[ ${CUSTOMBLOCKPAGE} == true ]]; then
echo " Existing blockingpage.css detected, not overwriting"
else
cp ${PI_HOLE_LOCAL_REPO}/advanced/blockingpage.css /var/www/html/pihole cp ${PI_HOLE_LOCAL_REPO}/advanced/blockingpage.css /var/www/html/pihole
echo " done!"
fi fi
else
cp ${PI_HOLE_LOCAL_REPO}/advanced/blockingpage.css /var/www/html/pihole
echo " done!"
fi
else else
echo "::: Creating directory for blocking page" echo "::: Creating directory for blocking page"
install -d /var/www/html/pihole install -d /var/www/html/pihole