diff --git a/tools/addon/add-netbird-lxc.sh b/tools/addon/add-netbird-lxc.sh index 4056c5776..aa008e0fc 100644 --- a/tools/addon/add-netbird-lxc.sh +++ b/tools/addon/add-netbird-lxc.sh @@ -79,6 +79,10 @@ EOF header_info msg "Installing NetBird..." pct exec "$CTID" -- bash -c ' +if ! command -v curl &>/dev/null; then + apt-get update -qq + apt-get install -y curl >/dev/null +fi apt install -y ca-certificates gpg &>/dev/null curl -fsSL "https://pkgs.netbird.io/debian/public.key" | gpg --dearmor >/usr/share/keyrings/netbird-archive-keyring.gpg echo "deb [signed-by=/usr/share/keyrings/netbird-archive-keyring.gpg] https://pkgs.netbird.io/debian stable main" >/etc/apt/sources.list.d/netbird.list diff --git a/tools/addon/add-tailscale-lxc.sh b/tools/addon/add-tailscale-lxc.sh index c671c02f6..838864013 100644 --- a/tools/addon/add-tailscale-lxc.sh +++ b/tools/addon/add-tailscale-lxc.sh @@ -89,6 +89,12 @@ if ! dig +short pkgs.tailscale.com | grep -qvE "^127\.|^0\.0\.0\.0$"; then echo "nameserver 1.1.1.1" >"$ORIG_RESOLV" fi +if ! command -v curl &>/dev/null; then + echo "[INFO] curl not found, installing..." + apt-get update -qq + apt-get install -y curl >/dev/null +fi + curl -fsSL https://pkgs.tailscale.com/stable/${ID}/${VER}.noarmor.gpg \ | tee /usr/share/keyrings/tailscale-archive-keyring.gpg >/dev/null diff --git a/tools/addon/adguardhome-sync.sh b/tools/addon/adguardhome-sync.sh index 8edac83f0..249223aaa 100644 --- a/tools/addon/adguardhome-sync.sh +++ b/tools/addon/adguardhome-sync.sh @@ -5,6 +5,11 @@ # License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE # Source: https://github.com/bakito/adguardhome-sync +if ! command -v curl &>/dev/null; then + printf "\r\e[2K%b" '\033[93m Setup Source \033[m' >&2 + apt-get update >/dev/null 2>&1 + apt-get install -y curl >/dev/null 2>&1 +fi source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/core.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/tools.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/error_handler.func) diff --git a/tools/addon/copyparty.sh b/tools/addon/copyparty.sh index c54cf6a22..058b0b21b 100644 --- a/tools/addon/copyparty.sh +++ b/tools/addon/copyparty.sh @@ -5,6 +5,11 @@ # License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE # Source: https://github.com/9001/copyparty +if ! command -v curl &>/dev/null; then + printf "\r\e[2K%b" '\033[93m Setup Source \033[m' >&2 + apt-get update >/dev/null 2>&1 + apt-get install -y curl >/dev/null 2>&1 +fi source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/core.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/tools.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/error_handler.func) diff --git a/tools/addon/filebrowser-quantum.sh b/tools/addon/filebrowser-quantum.sh index 6802b9fb9..33bb70997 100644 --- a/tools/addon/filebrowser-quantum.sh +++ b/tools/addon/filebrowser-quantum.sh @@ -110,6 +110,7 @@ if [[ -f "$INSTALL_PATH" ]]; then read -r update_prompt if [[ "${update_prompt,,}" =~ ^(y|yes)$ ]]; then msg_info "Updating ${APP}" + if ! command -v curl &>/dev/null; then $PKG_MANAGER curl &>/dev/null; fi curl -fsSL https://github.com/gtsteffaniak/filebrowser/releases/latest/download/linux-amd64-filebrowser -o "$TMP_BIN" chmod +x "$TMP_BIN" mv -f "$TMP_BIN" /usr/local/bin/filebrowser diff --git a/tools/addon/filebrowser.sh b/tools/addon/filebrowser.sh index 413e1b44f..620a57a79 100644 --- a/tools/addon/filebrowser.sh +++ b/tools/addon/filebrowser.sh @@ -88,6 +88,7 @@ if [ -f "$INSTALL_PATH" ]; then read -r -p "Would you like to update ${APP}? (y/N): " update_prompt if [[ "${update_prompt,,}" =~ ^(y|yes)$ ]]; then msg_info "Updating ${APP}" + if ! command -v curl &>/dev/null; then $PKG_MANAGER curl &>/dev/null; fi curl -fsSL "https://github.com/filebrowser/filebrowser/releases/latest/download/linux-amd64-filebrowser.tar.gz" | tar -xzv -C /usr/local/bin &>/dev/null chmod +x "$INSTALL_PATH" msg_ok "Updated ${APP}" diff --git a/tools/addon/glances.sh b/tools/addon/glances.sh index 4dec041e2..227d211e0 100644 --- a/tools/addon/glances.sh +++ b/tools/addon/glances.sh @@ -44,7 +44,7 @@ IP=$(get_lxc_ip) install_glances_debian() { msg_info "Installing dependencies" apt-get update >/dev/null 2>&1 - apt-get install -y gcc lm-sensors wireless-tools >/dev/null 2>&1 + apt-get install -y gcc lm-sensors wireless-tools curl >/dev/null 2>&1 msg_ok "Installed dependencies" msg_info "Setting up Python + uv" @@ -114,7 +114,7 @@ install_glances_alpine() { apk update >/dev/null 2>&1 $STD apk add --no-cache \ gcc musl-dev linux-headers python3-dev \ - python3 py3-pip py3-virtualenv lm-sensors wireless-tools >/dev/null 2>&1 + python3 py3-pip py3-virtualenv lm-sensors wireless-tools curl >/dev/null 2>&1 msg_ok "Installed dependencies" msg_info "Setting up Python + uv" diff --git a/tools/addon/immich-public-proxy.sh b/tools/addon/immich-public-proxy.sh index 77471722a..c98a92708 100644 --- a/tools/addon/immich-public-proxy.sh +++ b/tools/addon/immich-public-proxy.sh @@ -5,6 +5,11 @@ # License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE # Source: https://github.com/alangrainger/immich-public-proxy +if ! command -v curl &>/dev/null; then + printf "\r\e[2K%b" '\033[93m Setup Source \033[m' >&2 + apt-get update >/dev/null 2>&1 + apt-get install -y curl >/dev/null 2>&1 +fi source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/core.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/tools.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/error_handler.func) diff --git a/tools/addon/jellystat.sh b/tools/addon/jellystat.sh index 298adfb01..2afd4fa81 100644 --- a/tools/addon/jellystat.sh +++ b/tools/addon/jellystat.sh @@ -5,6 +5,11 @@ # License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE # Source: https://github.com/CyferShepard/Jellystat +if ! command -v curl &>/dev/null; then + printf "\r\e[2K%b" '\033[93m Setup Source \033[m' >&2 + apt-get update >/dev/null 2>&1 + apt-get install -y curl >/dev/null 2>&1 +fi source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/core.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/tools.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/error_handler.func) diff --git a/tools/addon/nextcloud-exporter.sh b/tools/addon/nextcloud-exporter.sh index 4e29f1680..60be17acb 100644 --- a/tools/addon/nextcloud-exporter.sh +++ b/tools/addon/nextcloud-exporter.sh @@ -5,6 +5,11 @@ # License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE # Source: https://github.com/xperimental/nextcloud-exporter +if ! command -v curl &>/dev/null; then + printf "\r\e[2K%b" '\033[93m Setup Source \033[m' >&2 + apt-get update >/dev/null 2>&1 + apt-get install -y curl >/dev/null 2>&1 +fi source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/core.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/tools.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/error_handler.func) diff --git a/tools/addon/olivetin.sh b/tools/addon/olivetin.sh index f20800b16..54672402a 100644 --- a/tools/addon/olivetin.sh +++ b/tools/addon/olivetin.sh @@ -51,6 +51,10 @@ function msg_ok() { } msg_info "Installing ${APP}" +if ! command -v curl &>/dev/null; then + apt-get update >/dev/null 2>&1 + apt-get install -y curl >/dev/null 2>&1 +fi curl -fsSL "https://github.com/OliveTin/OliveTin/releases/latest/download/OliveTin_linux_amd64.deb" -o $(basename "https://github.com/OliveTin/OliveTin/releases/latest/download/OliveTin_linux_amd64.deb") dpkg -i OliveTin_linux_amd64.deb &>/dev/null systemctl enable --now OliveTin &>/dev/null diff --git a/tools/addon/phpmyadmin.sh b/tools/addon/phpmyadmin.sh index 47ca2713c..f19a037bc 100644 --- a/tools/addon/phpmyadmin.sh +++ b/tools/addon/phpmyadmin.sh @@ -57,6 +57,10 @@ function msg_ok() { echo -e "${CM} ${GN}${1}${CL}"; } function msg_error() { echo -e "${CROSS} ${RD}${1}${CL}"; } function check_internet() { + if ! command -v curl &>/dev/null; then + apt-get update >/dev/null 2>&1 + apt-get install -y curl >/dev/null 2>&1 + fi msg_info "Checking Internet connectivity to GitHub" HTTP_CODE=$(curl -s -o /dev/null -w "%{http_code}" https://github.com) if [[ "$HTTP_CODE" -ge 200 && "$HTTP_CODE" -lt 400 ]]; then diff --git a/tools/addon/pihole-exporter.sh b/tools/addon/pihole-exporter.sh index 7aa959679..c2395d86c 100644 --- a/tools/addon/pihole-exporter.sh +++ b/tools/addon/pihole-exporter.sh @@ -5,6 +5,11 @@ # License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE # Source: https://github.com/eko/pihole-exporter/ +if ! command -v curl &>/dev/null; then + printf "\r\e[2K%b" '\033[93m Setup Source \033[m' >&2 + apt-get update >/dev/null 2>&1 + apt-get install -y curl >/dev/null 2>&1 +fi source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/core.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/tools.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/error_handler.func) diff --git a/tools/addon/qbittorrent-exporter.sh b/tools/addon/qbittorrent-exporter.sh index 39554384a..69bbb0884 100644 --- a/tools/addon/qbittorrent-exporter.sh +++ b/tools/addon/qbittorrent-exporter.sh @@ -5,6 +5,11 @@ # License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE # Source: https://github.com/martabal/qbittorrent-exporter +if ! command -v curl &>/dev/null; then + printf "\r\e[2K%b" '\033[93m Setup Source \033[m' >&2 + apt-get update >/dev/null 2>&1 + apt-get install -y curl >/dev/null 2>&1 +fi source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/core.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/tools.func) source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/error_handler.func) diff --git a/tools/addon/webmin.sh b/tools/addon/webmin.sh index ab9a9bea7..2df075772 100644 --- a/tools/addon/webmin.sh +++ b/tools/addon/webmin.sh @@ -42,7 +42,7 @@ whiptail --backtitle "Proxmox VE Helper Scripts" --title "Webmin Installer" --ye msg_info "Installing Prerequisites" apt update &>/dev/null -apt-get -y install libnet-ssleay-perl libauthen-pam-perl libio-pty-perl unzip shared-mime-info &>/dev/null +apt-get -y install libnet-ssleay-perl libauthen-pam-perl libio-pty-perl unzip shared-mime-info curl &>/dev/null msg_ok "Installed Prerequisites" LATEST=$(curl -fsSL https://api.github.com/repos/webmin/webmin/releases/latest | grep '"tag_name":' | cut -d'"' -f4)