From 00d1966533e0a4774ac379a4c04d9517a1412f0a Mon Sep 17 00:00:00 2001 From: MickLesk Date: Mon, 23 Mar 2026 21:48:48 +0100 Subject: [PATCH] fix(turnkey): replace diagnostics_check with inline config read MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit diagnostics_check() is defined in build.func which is not sourced. Read the diagnostics config file directly instead — respects existing user preference without prompting (turnkey has no settings menu). --- turnkey/turnkey.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/turnkey/turnkey.sh b/turnkey/turnkey.sh index b9558182c..91e274d9c 100644 --- a/turnkey/turnkey.sh +++ b/turnkey/turnkey.sh @@ -152,7 +152,13 @@ fi pve_check shell_check root_check -diagnostics_check + +# Read diagnostics preference (same logic as build.func diagnostics_check) +DIAG_CONFIG="/usr/local/community-scripts/diagnostics" +if [[ -f "$DIAG_CONFIG" ]]; then + DIAGNOSTICS=$(awk -F '=' '/^DIAGNOSTICS/ {print $2}' "$DIAG_CONFIG") || true + DIAGNOSTICS="${DIAGNOSTICS:-no}" +fi header_info whiptail --backtitle "Proxmox VE Helper Scripts" --title "TurnKey LXCs" --yesno \