mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-10-08 20:11:02 +02:00
feat: update nginx proxy manager to trixie (#15457)
* Add host-migrate.sh Proxmox VE tool Add tools/pve/host-migrate.sh — an interactive Proxmox VE host migration utility. The script (whiptail UI) can export host configuration, /etc tarball, SSH keys, APT state and LXC/QEMU guests (vzdump or config-only) into a timestamped bundle, with optional on-demand NFS mounting. It also supports importing bundles to restore guests and selective host components (storage, users, SSH, APT, hosts, network, hostname) with explicit warnings for dangerous operations (network/hostname). Implements preflight checks, manifest creation, storage mapping checks, cleanup trap for NFS, and integrates helper functions loaded from the project's core scripts. * Improve storage prep & mounting in host-migrate Add interactive storage preparation and safer mount handling for host-migrate. - Track and clean up on-demand mounts via TEMP_MOUNTS and extend cleanup handler. - Add helpers: _new_mountpoint, _offer_fstab, mount_existing_fs, format_and_mount, create_lv_and_mount to mount, format, or create LVs and optionally persist to /etc/fstab. - Enhance browse_mounts to list unmounted block devices and LVM VGs, offer mount/format/LV creation, and return prepared mount via BROWSE_RESULT. - Integrate prepared target into choose_location and do_export; show free-space warning before export. - Improve vzdump output detection to pick the newest non-log file. - Minor UX/message tweaks and quoting fixes for backup filenames when restoring storage.cfg and /etc/hosts. These changes let users pick or prepare target storage (mount existing FS, format disks, create LVs) interactively and ensures temporary mounts are cleaned up. * hardcode openresty version and build it from website release * change libpcre3-dev to libpcre2-dev * Delete tools/pve/host-migrate.sh --------- Co-authored-by: MickLesk <mickey.leskowitz@gmail.com>
This commit is contained in:
@@ -11,7 +11,7 @@ var_cpu="${var_cpu:-2}"
|
|||||||
var_ram="${var_ram:-2048}"
|
var_ram="${var_ram:-2048}"
|
||||||
var_disk="${var_disk:-8}"
|
var_disk="${var_disk:-8}"
|
||||||
var_os="${var_os:-debian}"
|
var_os="${var_os:-debian}"
|
||||||
var_version="${var_version:-12}"
|
var_version="${var_version:-13}"
|
||||||
var_arm64="${var_arm64:-yes}"
|
var_arm64="${var_arm64:-yes}"
|
||||||
var_unprivileged="${var_unprivileged:-1}"
|
var_unprivileged="${var_unprivileged:-1}"
|
||||||
|
|
||||||
@@ -60,8 +60,9 @@ function update_script() {
|
|||||||
fi
|
fi
|
||||||
$STD apt install -y build-essential "$pcre_pkg" libssl-dev zlib1g-dev
|
$STD apt install -y build-essential "$pcre_pkg" libssl-dev zlib1g-dev
|
||||||
|
|
||||||
if check_for_gh_release "openresty" "openresty/openresty"; then
|
OPENRESTY_VERSION="1.29.2.5"
|
||||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "openresty" "openresty/openresty" "prebuild" "${CHECK_UPDATE_RELEASE}" "/opt/openresty" "openresty-*.tar.gz"
|
if [[ "$(cat ~/.openresty 2>/dev/null)" != "$OPENRESTY_VERSION" ]]; then
|
||||||
|
CLEAN_INSTALL=1 fetch_and_deploy_from_url "https://openresty.org/download/openresty-${OPENRESTY_VERSION}.tar.gz" "/opt/openresty"
|
||||||
|
|
||||||
msg_info "Building OpenResty"
|
msg_info "Building OpenResty"
|
||||||
cd /opt/openresty
|
cd /opt/openresty
|
||||||
@@ -77,6 +78,7 @@ function update_script() {
|
|||||||
--with-stream_ssl_module
|
--with-stream_ssl_module
|
||||||
$STD make -j"$(nproc)"
|
$STD make -j"$(nproc)"
|
||||||
$STD make install
|
$STD make install
|
||||||
|
echo "${OPENRESTY_VERSION}" >~/.openresty
|
||||||
rm -rf /opt/openresty
|
rm -rf /opt/openresty
|
||||||
cat <<'EOF' >/lib/systemd/system/openresty.service
|
cat <<'EOF' >/lib/systemd/system/openresty.service
|
||||||
[Unit]
|
[Unit]
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ $STD apt install -y \
|
|||||||
apache2-utils \
|
apache2-utils \
|
||||||
logrotate \
|
logrotate \
|
||||||
build-essential \
|
build-essential \
|
||||||
libpcre3-dev \
|
libpcre2-dev \
|
||||||
libssl-dev \
|
libssl-dev \
|
||||||
zlib1g-dev \
|
zlib1g-dev \
|
||||||
git \
|
git \
|
||||||
@@ -36,7 +36,8 @@ $STD /opt/certbot/bin/pip install certbot certbot-dns-cloudflare
|
|||||||
ln -sf /opt/certbot/bin/certbot /usr/local/bin/certbot
|
ln -sf /opt/certbot/bin/certbot /usr/local/bin/certbot
|
||||||
msg_ok "Set up Certbot"
|
msg_ok "Set up Certbot"
|
||||||
|
|
||||||
fetch_and_deploy_gh_release "openresty" "openresty/openresty" "prebuild" "latest" "/opt/openresty" "openresty-*.tar.gz"
|
OPENRESTY_VERSION="1.29.2.5"
|
||||||
|
fetch_and_deploy_from_url "https://openresty.org/download/openresty-${OPENRESTY_VERSION}.tar.gz" "/opt/openresty"
|
||||||
|
|
||||||
msg_info "Building OpenResty"
|
msg_info "Building OpenResty"
|
||||||
cd /opt/openresty
|
cd /opt/openresty
|
||||||
@@ -52,6 +53,7 @@ $STD ./configure \
|
|||||||
--with-stream_ssl_module
|
--with-stream_ssl_module
|
||||||
$STD make -j"$(nproc)"
|
$STD make -j"$(nproc)"
|
||||||
$STD make install
|
$STD make install
|
||||||
|
echo "${OPENRESTY_VERSION}" >~/.openresty
|
||||||
rm -rf /opt/openresty
|
rm -rf /opt/openresty
|
||||||
|
|
||||||
cat <<'EOF' >/lib/systemd/system/openresty.service
|
cat <<'EOF' >/lib/systemd/system/openresty.service
|
||||||
|
|||||||
Reference in New Issue
Block a user