mirror of
https://github.com/pi-hole/pi-hole.git
synced 2024-12-27 23:32:21 +00:00
Don't attempt writing to pihole.toml if file does not exit. FTL needs to be started first
Signed-off-by: Christian König <github@yubiuser.dev>
This commit is contained in:
parent
cd8d9ab84e
commit
3956ca49b6
1 changed files with 10 additions and 9 deletions
|
@ -2367,15 +2367,6 @@ main() {
|
|||
pihole -a -p "${pw}"
|
||||
fi
|
||||
|
||||
# write privacy level and logging to pihole.toml
|
||||
# set on fresh installations by setPrivacyLevel() and setLogging(
|
||||
if [ -n "${QUERY_LOGGING}" ]; then
|
||||
pihole-FTL --config dns.queryLogging "${QUERY_LOGGING}"
|
||||
fi
|
||||
if [ -n "${PRIVACY_LEVEL}" ]; then
|
||||
pihole-FTL --config misc.privacylevel "${PRIVACY_LEVEL}"
|
||||
fi
|
||||
|
||||
# Migrate existing install to v6.0
|
||||
migrate_dnsmasq_configs
|
||||
|
||||
|
@ -2401,6 +2392,16 @@ main() {
|
|||
|
||||
restart_service pihole-FTL
|
||||
|
||||
# write privacy level and logging to pihole.toml
|
||||
# needs to be done after FTL service has been started, otherwise pihole.toml does not exist
|
||||
# set on fresh installations by setPrivacyLevel() and setLogging(
|
||||
if [ -n "${QUERY_LOGGING}" ]; then
|
||||
pihole-FTL --config dns.queryLogging "${QUERY_LOGGING}"
|
||||
fi
|
||||
if [ -n "${PRIVACY_LEVEL}" ]; then
|
||||
pihole-FTL --config misc.privacylevel "${PRIVACY_LEVEL}"
|
||||
fi
|
||||
|
||||
# Download and compile the aggregated block list
|
||||
runGravity
|
||||
|
||||
|
|
Loading…
Reference in a new issue