Merge pull request #95 from wtreur/dev

Ensured setupVars.conf is always present when changing settings from start.sh
This commit is contained in:
Adam Hill 2017-01-21 18:33:46 -06:00 committed by GitHub
commit bdc439f84c
2 changed files with 5 additions and 0 deletions

View File

@ -1,5 +1,9 @@
. /opt/pihole/webpage.sh
prepare_setup_vars() {
touch $setupVars
}
validate_env() {
if [ -z "$ServerIP" ] ; then
echo "ERROR: To function correctly you must pass an environment variables of 'ServerIP' into the docker container with the IP of your docker host from which you are passing web (80) and dns (53) ports from"

View File

@ -17,6 +17,7 @@ export IPv6
echo " ::: Starting docker specific setup for docker diginc/pi-hole"
validate_env
prepare_setup_vars
change_setting "IPV4_ADDRESS" "$ServerIP"
change_setting "IPV6_ADDRESS" "$ServerIPv6"
setup_dnsmasq_dns "$DNS1" "$DNS2"