mirror of
https://github.com/pi-hole/docker-pi-hole.git
synced 2025-12-19 18:08:35 +00:00
@@ -104,11 +104,9 @@ migrate_gravity() {
|
||||
echo " [i] Gravity migration checks"
|
||||
gravityDBfile=$(getFTLConfigValue files.gravity)
|
||||
|
||||
if [[ -z "${PYTEST}" ]]; then
|
||||
if [[ ! -f /etc/pihole/adlists.list ]]; then
|
||||
echo " [i] No adlist file found, creating one with a default blocklist"
|
||||
echo "https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts" >/etc/pihole/adlists.list
|
||||
fi
|
||||
if [[ ! -f /etc/pihole/adlists.list ]]; then
|
||||
echo " [i] No adlist file found, creating one with a default blocklist"
|
||||
echo "https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts" >/etc/pihole/adlists.list
|
||||
fi
|
||||
|
||||
if [ ! -f "${gravityDBfile}" ]; then
|
||||
|
||||
@@ -146,12 +146,6 @@ stop() {
|
||||
echo " https://docs.docker.com/engine/containers/start-containers-automatically/#use-a-restart-policy"
|
||||
echo ""
|
||||
|
||||
# If we are running pytest, keep the container alive for a little longer
|
||||
# to allow the tests to complete
|
||||
if [[ ${PYTEST} ]]; then
|
||||
sleep 10
|
||||
fi
|
||||
|
||||
exit "${FTL_EXIT_CODE}"
|
||||
|
||||
}
|
||||
|
||||
@@ -45,10 +45,6 @@ def docker(request):
|
||||
for env_var in env_vars:
|
||||
cmd.extend(["-e", env_var])
|
||||
|
||||
# ensure PYTEST=1 is set
|
||||
if not any("PYTEST=1" in arg for arg in cmd):
|
||||
cmd.extend(["-e", "PYTEST=1"])
|
||||
|
||||
# add default TZ if not already set
|
||||
if not any("TZ=" in arg for arg in cmd):
|
||||
cmd.extend(["-e", 'TZ="Europe/London"'])
|
||||
|
||||
Reference in New Issue
Block a user