From d11c409563e88228f0938d783c5d3c8bcb0ca09c Mon Sep 17 00:00:00 2001 From: "CanbiZ (MickLesk)" <47820557+MickLesk@users.noreply.github.com> Date: Fri, 10 Apr 2026 10:25:22 +0200 Subject: [PATCH] fix(filebrowser): improve host warning text and add to filebrowser addon - Clarify that passthrough drives are not visible on the Proxmox host - Mention incorrect disk usage stats and incomplete file browsing - Add same warning to filebrowser (non-quantum) addon which also serves from / - Reduce verbosity, remove redundant phrasing --- tools/addon/filebrowser-quantum.sh | 14 +++++++------- tools/addon/filebrowser.sh | 15 +++++++++++++++ 2 files changed, 22 insertions(+), 7 deletions(-) diff --git a/tools/addon/filebrowser-quantum.sh b/tools/addon/filebrowser-quantum.sh index 8b5203d41..c2f743f32 100644 --- a/tools/addon/filebrowser-quantum.sh +++ b/tools/addon/filebrowser-quantum.sh @@ -45,16 +45,16 @@ IP=$(ip -4 addr show "$IFACE" | awk '/inet / {print $2}' | cut -d/ -f1 | head -n # Proxmox Host Warning if [[ -d "/etc/pve" ]]; then - echo -e "${RD}⚠️ WARNING: You are running this on a Proxmox host!${CL}" - echo -e "${YW} The recommended installation method is via LXC:${CL}" - echo -e "${YW} https://community-scripts.github.io/ProxmoxVE/scripts?id=filebrowser-quantum${CL}" - echo -e "${YW} Installing directly on the host can cause incorrect size calculations${CL}" - echo -e "${YW} and indexing issues. Proceed at your own risk.${CL}" + echo -e "${RD}⚠️ Warning: Running this addon directly on the Proxmox host is not recommended!${CL}" + echo -e "${YW} Only the boot disk will be visible — passthrough drives will not be indexed.${CL}" + echo -e "${YW} This causes incorrect disk usage stats and incomplete file browsing.${CL}" + echo -e "${YW} Please use the dedicated LXC installer instead and mount your drives there:${CL}" + echo -e "${YW} https://community-scripts.org/scripts/filebrowser-quantum${CL}" echo "" - echo -n "Continue installation on the Proxmox host anyway? (y/N): " + echo -n "Continue anyway on the Proxmox host? (y/N): " read -r host_confirm if [[ ! "${host_confirm,,}" =~ ^(y|yes)$ ]]; then - echo -e "${YW}Aborted. Please use the LXC installer instead.${CL}" + echo -e "${YW}Aborted.${CL}" exit 0 fi fi diff --git a/tools/addon/filebrowser.sh b/tools/addon/filebrowser.sh index 93ad3db64..9a04138cb 100644 --- a/tools/addon/filebrowser.sh +++ b/tools/addon/filebrowser.sh @@ -41,6 +41,21 @@ IP=$(ip -4 addr show "$IFACE" | awk '/inet / {print $2}' | cut -d/ -f1 | head -n [[ -z "$IP" ]] && IP=$(hostname -I | awk '{print $1}') [[ -z "$IP" ]] && IP="127.0.0.1" +# Proxmox Host Warning +if [[ -d "/etc/pve" ]]; then + echo -e "${RD}⚠️ Warning: Running this addon directly on the Proxmox host is not recommended!${CL}" + echo -e "${YW} Only the boot disk will be visible — passthrough drives will not be indexed.${CL}" + echo -e "${YW} This causes incorrect disk usage stats and incomplete file browsing.${CL}" + echo -e "${YW} Install this addon inside an LXC and mount your drives there instead.${CL}" + echo "" + echo -n "Continue anyway on the Proxmox host? (y/N): " + read -r host_confirm + if [[ ! "${host_confirm,,}" =~ ^(y|yes)$ ]]; then + echo -e "${YW}Aborted.${CL}" + exit 0 + fi +fi + # Detect OS if [[ -f "/etc/alpine-release" ]]; then OS="Alpine"