diff --git a/ct/technitiumdns.sh b/ct/technitiumdns.sh index 37cd88963..4ec9e3893 100644 --- a/ct/technitiumdns.sh +++ b/ct/technitiumdns.sh @@ -28,6 +28,11 @@ function update_script() { exit fi + if is_package_installed "aspnetcore-runtime-8.0"; then + $STD apt remove -y aspnetcore-runtime-8.0 + $STD apt install -y aspnetcore-runtime-9.0 + fi + RELEASE=$(curl -fsSL https://technitium.com/dns/ | grep -oP 'Version \K[\d.]+') if [[ ! -f ~/.technitium || "${RELEASE}" != "$(cat ~/.technitium)" ]]; then msg_info "Updating Technitium DNS" diff --git a/install/technitiumdns-install.sh b/install/technitiumdns-install.sh index f15e7c925..2d4a5853d 100644 --- a/install/technitiumdns-install.sh +++ b/install/technitiumdns-install.sh @@ -18,7 +18,7 @@ curl -fsSL "https://packages.microsoft.com/config/debian/12/packages-microsoft-p $STD dpkg -i packages-microsoft-prod.deb rm -rf packages-microsoft-prod.deb $STD apt update -$STD apt install -y aspnetcore-runtime-8.0 +$STD apt install -y aspnetcore-runtime-9.0 msg_ok "Installed ASP.NET Core Runtime" RELEASE=$(curl -fsSL https://technitium.com/dns/ | grep -oP 'Version \K[\d.]+') @@ -26,20 +26,15 @@ msg_info "Installing Technitium DNS" mkdir -p /opt/technitium/dns curl -fsSL "https://download.technitium.com/dns/DnsServerPortable.tar.gz" -o /opt/DnsServerPortable.tar.gz $STD tar zxvf /opt/DnsServerPortable.tar.gz -C /opt/technitium/dns/ +rm -f /opt/DnsServerPortable.tar.gz echo "${RELEASE}" >~/.technitium msg_ok "Installed Technitium DNS" msg_info "Creating service" cp /opt/technitium/dns/systemd.service /etc/systemd/system/technitium.service -systemctl enable -q --now technitium +systemctl enable -q --now technitium msg_ok "Service created" motd_ssh customize - -msg_info "Cleaning up" -rm -f /opt/DnsServerPortable.tar.gz -$STD apt -y autoremove -$STD apt -y autoclean -$STD apt -y clean -msg_ok "Cleaned" +cleanup_lxc