Update adguard.sh (#1343)

Fix for DNS lookup failing during wget command.
This commit is contained in:
Chris Heath 2023-04-18 06:12:17 -05:00 committed by GitHub
parent 5d7da7e833
commit 202827ce41
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -54,12 +54,12 @@ function default_settings() {
function update_script() { function update_script() {
header_info header_info
if [[ ! -d /opt/AdGuardHome ]]; then msg_error "No ${APP} Installation Found!"; exit; fi if [[ ! -d /opt/AdGuardHome ]]; then msg_error "No ${APP} Installation Found!"; exit; fi
wget -qL https://static.adguard.com/adguardhome/release/AdGuardHome_linux_amd64.tar.gz
msg_info "Stopping AdguardHome" msg_info "Stopping AdguardHome"
systemctl stop AdGuardHome systemctl stop AdGuardHome
msg_ok "Stopped AdguardHome" msg_ok "Stopped AdguardHome"
msg_info "Updating AdguardHome" msg_info "Updating AdguardHome"
wget -qL https://static.adguard.com/adguardhome/release/AdGuardHome_linux_amd64.tar.gz
tar -xvf AdGuardHome_linux_amd64.tar.gz &>/dev/null tar -xvf AdGuardHome_linux_amd64.tar.gz &>/dev/null
mkdir -p adguard-backup mkdir -p adguard-backup
cp -r /opt/AdGuardHome/AdGuardHome.yaml /opt/AdGuardHome/data adguard-backup/ cp -r /opt/AdGuardHome/AdGuardHome.yaml /opt/AdGuardHome/data adguard-backup/
@ -74,7 +74,7 @@ msg_ok "Started AdguardHome"
msg_info "Cleaning Up" msg_info "Cleaning Up"
rm -rf AdGuardHome_linux_amd64.tar.gz AdGuardHome adguard-backup rm -rf AdGuardHome_linux_amd64.tar.gz AdGuardHome adguard-backup
msg_ok "Cleaned" msg_ok "Cleaned"
msg_ok "Update Successfull" msg_ok "Update Successful"
exit exit
} }