mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-11-03 12:04:31 +01:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| a5e2a50cd6 | |||
| d9abcadd01 |
+5
-3
@@ -581,10 +581,12 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
|
||||
|
||||
### 💾 Core
|
||||
|
||||
- feat: add var_cmode to set the container console mode [@MickLesk](https://github.com/MickLesk) ([core#180](https://github.com/community-scripts/core/pull/180))
|
||||
- fix: restore npm when an interrupted update left it behind [@MickLesk](https://github.com/MickLesk) ([core#189](https://github.com/community-scripts/core/pull/189))
|
||||
- feat: find the assets of a renamed GitHub repo without the API [@MickLesk](https://github.com/MickLesk) ([core#188](https://github.com/community-scripts/core/pull/188))
|
||||
- fix: pve-LXC: say when the container went away during its setup [@MickLesk](https://github.com/MickLesk) ([core#192](https://github.com/community-scripts/core/pull/192))
|
||||
- fix: treat Esc in a VM wizard dialog as leaving the script [@MickLesk](https://github.com/MickLesk) ([core#190](https://github.com/community-scripts/core/pull/190))
|
||||
- ref: count a container stopped during a detached install as an abort [@MickLesk](https://github.com/MickLesk) ([core#187](https://github.com/community-scripts/core/pull/187))
|
||||
- feat: find the assets of a renamed GitHub repo without the API [@MickLesk](https://github.com/MickLesk) ([core#188](https://github.com/community-scripts/core/pull/188))
|
||||
- fix: restore npm when an interrupted update left it behind [@MickLesk](https://github.com/MickLesk) ([core#189](https://github.com/community-scripts/core/pull/189))
|
||||
- feat: add var_cmode to set the container console mode [@MickLesk](https://github.com/MickLesk) ([core#180](https://github.com/community-scripts/core/pull/180))
|
||||
|
||||
## 2026-11-02
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
# https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
function header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
________ __ _ ________
|
||||
/ ____/ /__ ____ _____ / / | |/ / ____/
|
||||
|
||||
@@ -19,7 +19,7 @@ CONF_FILE="/etc/update-lxcs.conf"
|
||||
LOG_FILE="/var/log/update-lxcs-cron.log"
|
||||
CRON_ENTRY="0 0 * * 0 ${LOCAL_SCRIPT} >>${LOG_FILE} 2>&1"
|
||||
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
______ __ __ __ __ __ _ ________
|
||||
/ ____/________ ____ / / / /___ ____/ /___ _/ /____ / / | |/ / ____/____
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
# https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
function header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
______ __ __ _ ________
|
||||
/ ____/ _____ _______ __/ /____ / / | |/ / ____/
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
set -eEuo pipefail
|
||||
|
||||
function header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
_______ __ __ ______ _
|
||||
/ ____(_) /__ _______ _______/ /____ ____ ___ /_ __/____(_)___ ___
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
function header_info {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
____ ______ __ ____ __ __
|
||||
/ __ \_________ _ ______ ___ ____ _ __ / ____/_ _____ _____/ /_ / __ \___ / /__ / /____
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
set -e
|
||||
function header_info {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
|
||||
__ ___ __ ___ __ __ _
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
# https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
____ ____ __________ __ ______ __________ ___ ____ ______
|
||||
/ __ \/ __ ) ___/__ / / / / / __ \/ ____/ __ \/ | / __ \/ ____/
|
||||
@@ -168,7 +168,7 @@ while true; do
|
||||
case $yn in
|
||||
[Yy]*) break ;;
|
||||
[Nn]*)
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
exit
|
||||
;;
|
||||
*) echo "Please answer yes or no." ;;
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
____ ____ _____ __ __ __ __ __
|
||||
/ __ \/ __ ) ___// // / / / / /___ ____ __________ _____/ /__
|
||||
@@ -192,7 +192,7 @@ while true; do
|
||||
case $yn in
|
||||
[Yy]*) break ;;
|
||||
[Nn]*)
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
exit
|
||||
;;
|
||||
*) echo "Please answer yes or no." ;;
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
____ ____ _____ ____ __ ____ __ ____
|
||||
/ __ \/ __ ) ___/ / __ \____ _____/ /_ / _/___ _____/ /_____ _/ / /
|
||||
@@ -89,7 +89,7 @@ main() {
|
||||
case $yn in
|
||||
[Yy]*) break ;;
|
||||
[Nn]*)
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
exit
|
||||
;;
|
||||
*) echo "Please answer yes or no." ;;
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
____ ____ __ ___ ____ __ ____ __ ____
|
||||
/ __ \/ __ \/ |/ / / __ \____ _____/ /_ / _/___ _____/ /_____ _/ / /
|
||||
@@ -412,7 +412,7 @@ while true; do
|
||||
case $yn in
|
||||
[Yy]*) break ;;
|
||||
[Nn]*)
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
exit
|
||||
;;
|
||||
*) echo "Please answer yes or no." ;;
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
____ __ _________ ____ __ ____ __ ____
|
||||
/ __ \/ |/ / ____/ / __ \____ _____/ /_ / _/___ _____/ /_____ _/ / /
|
||||
@@ -410,7 +410,7 @@ while true; do
|
||||
case $yn in
|
||||
[Yy]*) break ;;
|
||||
[Nn]*)
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
exit
|
||||
;;
|
||||
*) echo "Please answer yes or no." ;;
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
# https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
____ _ ________ ____ __ ____ __ ____
|
||||
/ __ \ | / / ____/ / __ \____ _____/ /_ / _/___ _____/ /_____ _/ / /
|
||||
@@ -81,7 +81,7 @@ main() {
|
||||
case $yn in
|
||||
[Yy]*) break ;;
|
||||
[Nn]*)
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
exit
|
||||
;;
|
||||
*) echo "Please answer yes or no." ;;
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
# https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
____ _ ____________ __ ______ __________ ___ ____ ______
|
||||
/ __ \ | / / ____( __ ) / / / / __ \/ ____/ __ \/ | / __ \/ ____/
|
||||
@@ -118,7 +118,7 @@ while true; do
|
||||
case $yn in
|
||||
[Yy]*) break ;;
|
||||
[Nn]*)
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
exit
|
||||
;;
|
||||
*) echo "Please answer yes or no." ;;
|
||||
|
||||
@@ -11,7 +11,7 @@ source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent
|
||||
declare -f init_tool_telemetry &>/dev/null && init_tool_telemetry "scaling-governor" "pve"
|
||||
|
||||
header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<EOF
|
||||
________ __ __ _____
|
||||
/ ___/ _ \/ / / / / ___/__ _ _____ _______ ___ _______
|
||||
@@ -26,7 +26,7 @@ GOV_BASE="/sys/devices/system/cpu/cpu0/cpufreq"
|
||||
if [[ ! -r "$GOV_BASE/scaling_governor" || ! -r "$GOV_BASE/scaling_available_governors" ]]; then
|
||||
whiptail --backtitle "Proxmox VE Helper Scripts" --title "CPU Scaling Not Available" \
|
||||
--msgbox "CPU frequency scaling is not available on this system.\n\nThis is normal when no cpufreq driver is active (e.g. CPU power management handled by the BIOS, or certain virtualized hosts)." 12 70
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
exit 0
|
||||
fi
|
||||
|
||||
@@ -42,7 +42,7 @@ done < <(tr ' ' '\n' <"$GOV_BASE/scaling_available_governors" | sed '/^$/d' | gr
|
||||
scaling_governor=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "Current CPU Scaling Governor is set to $current_governor" --radiolist "\nSelect the Scaling Governor to use:\n" 16 $((MSG_MAX_LENGTH + 58)) 6 "${GOVERNORS_MENU[@]}" 3>&1 1>&2 2>&3 | tr -d '"')
|
||||
[ -z "$scaling_governor" ] && {
|
||||
whiptail --backtitle "Proxmox VE Helper Scripts" --title "No CPU Scaling Governor Selected" --msgbox "It appears that no CPU Scaling Governor was selected" 10 68
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
exit
|
||||
}
|
||||
echo "${scaling_governor}" | tee /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor >/dev/null
|
||||
|
||||
@@ -11,7 +11,7 @@ declare -f init_tool_telemetry &>/dev/null && init_tool_telemetry "storage-share
|
||||
set -eEuo pipefail
|
||||
|
||||
function header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
_____ __ ___ _________
|
||||
/ ___// /_____ _________ _____ ____ / | / _/ __ \
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
# https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
function header_info() {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
__ __ __ __ __ _ ________
|
||||
/ / / /___ ____/ /___ _/ /____ / / | |/ / ____/
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
# https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
function header_info {
|
||||
clear
|
||||
clear 2>/dev/null || printf '\033[H\033[2J\033[3J'
|
||||
cat <<"EOF"
|
||||
__ __ __ __ ____
|
||||
/ / / /___ ____/ /___ _/ /____ / __ \___ ____ ____
|
||||
|
||||
+15
-9
@@ -47,7 +47,7 @@ function check_disk_space() {
|
||||
}
|
||||
|
||||
TEMP_DIR=$(mktemp -d)
|
||||
if ! check_disk_space "$TEMP_DIR" 4 && [ -d "/var/tmp" ] && check_disk_space "/var/tmp" 4; then
|
||||
if ! check_disk_space "$TEMP_DIR" 20 && [ -d "/var/tmp" ] && check_disk_space "/var/tmp" 20; then
|
||||
rm -rf "$TEMP_DIR"
|
||||
TEMP_DIR=$(mktemp -d /var/tmp/opnsense-vm.XXXXXX)
|
||||
fi
|
||||
@@ -364,6 +364,15 @@ FREEBSD_VER="$VM_INDEX_LATEST"
|
||||
URL="$VM_INDEX_URL"
|
||||
msg_ok "Download URL: ${CL}${BL}${URL}${CL}"
|
||||
|
||||
# Check available disk space (require at least 20GB for safety)
|
||||
if ! check_disk_space "$TEMP_DIR" 20; then
|
||||
AVAILABLE_GB=$(df -h "$TEMP_DIR" | awk 'NR==2 {print $4}')
|
||||
msg_error "Insufficient disk space in temporary directory ($TEMP_DIR)."
|
||||
msg_error "Available: ${AVAILABLE_GB}, Required: ~20GB for FreeBSD image decompression."
|
||||
msg_error "Please free up space or ensure /tmp has sufficient storage."
|
||||
exit 214
|
||||
fi
|
||||
|
||||
msg_info "Downloading FreeBSD Image"
|
||||
# A mirror serving an error page returns 200, so size decides whether this
|
||||
# is an image. Anything real here is far above 5 MB.
|
||||
@@ -372,14 +381,11 @@ vm_fetch_image "$URL" "$CACHE_FILE" --cache --verify-xz --min-bytes $((5 * 1024
|
||||
echo -en "\e[1A\e[0K"
|
||||
msg_ok "Downloaded ${CL}${BL}$(basename "$CACHE_FILE")${CL}"
|
||||
|
||||
# The download sits in the image cache; only the unpacked image (2.5 GB for
|
||||
# FreeBSD 15.1, not 20) lands in TEMP_DIR, and xz knows its size up front.
|
||||
NEED_GB=$(($(xz --robot -l "$CACHE_FILE" | awk '$1 == "totals" {print $5}') / 1024 / 1024 / 1024 + 1))
|
||||
if ! check_disk_space "$TEMP_DIR" "$NEED_GB"; then
|
||||
# Check disk space again before decompression
|
||||
if ! check_disk_space "$TEMP_DIR" 15; then
|
||||
AVAILABLE_GB=$(df -h "$TEMP_DIR" | awk 'NR==2 {print $4}')
|
||||
msg_error "Insufficient disk space for decompression in ${TEMP_DIR}."
|
||||
msg_error "Available: ${AVAILABLE_GB}, Required: ~${NEED_GB}GB for the decompressed image."
|
||||
msg_error "Please free up space or ensure /tmp or /var/tmp has sufficient storage."
|
||||
msg_error "Insufficient disk space for decompression."
|
||||
msg_error "Available: ${AVAILABLE_GB}, Required: ~15GB for decompressed image."
|
||||
exit 214
|
||||
fi
|
||||
|
||||
@@ -411,7 +417,7 @@ while :; do
|
||||
alloc_delay=$((alloc_delay * 2))
|
||||
continue
|
||||
fi
|
||||
msg_error "Could not allocate the EFI disk on ${STORAGE}: ${alloc_err}"
|
||||
echo -e "$alloc_err" >&2
|
||||
exit 220
|
||||
done
|
||||
vm_import_disk "$VMID" "$FILE" "$STORAGE"
|
||||
|
||||
Reference in New Issue
Block a user