Compare commits

..

3 Commits

Author SHA1 Message Date
github-actions[bot]
3b25bd9caa Update CHANGELOG.md 2026-04-12 19:33:32 +00:00
community-scripts-pr-app[bot]
6a86f52c0e Update CHANGELOG.md (#13695)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-12 19:33:13 +00:00
CanbiZ (MickLesk)
346dfd8bf7 Alpine-Wakapi: Remove container checks in update_script function (#13694) 2026-04-12 21:32:51 +02:00
4 changed files with 25 additions and 84 deletions

View File

@@ -446,8 +446,13 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- Alpine-Wakapi: Remove container checks in update_script function [@MickLesk](https://github.com/MickLesk) ([#13694](https://github.com/community-scripts/ProxmoxVE/pull/13694))
- #### 🔧 Refactor
- IronClaw: Install keychain dependencies and launch in a DBus session [@MickLesk](https://github.com/MickLesk) ([#13692](https://github.com/community-scripts/ProxmoxVE/pull/13692))
- MeTube: Allow pnpm build scripts to fix ERR_PNPM_IGNORED_BUILDS [@MickLesk](https://github.com/MickLesk) ([#13668](https://github.com/community-scripts/ProxmoxVE/pull/13668))
## 2026-04-11

View File

@@ -22,8 +22,6 @@ catch_errors
function update_script() {
header_info
check_container_storage
check_container_resources
if [[ ! -d /opt/wakapi ]]; then
msg_error "No ${APP} Installation Found!"
exit

View File

@@ -21,13 +21,6 @@ setup_deb822_repo \
"trixie" \
"pmg-no-subscription"
$STD apt install -y proxmox-mailgateway-container
msg_info "Cleaning up duplicate APT sources"
rm -f /etc/apt/sources.list.d/pmg-enterprise.list
rm -f /etc/apt/sources.list.d/pmg-install-repo.list
[[ -f /etc/apt/sources.list.d/debian.sources ]] && : >/etc/apt/sources.list
msg_ok "Cleaned up duplicate APT sources"
msg_ok "Installed Proxmox Mail Gateway"
motd_ssh

View File

@@ -47,8 +47,7 @@ msg_error() {
source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/api.func) 2>/dev/null || true
declare -f init_tool_telemetry &>/dev/null && init_tool_telemetry "post-pmg-install" "pve"
if ! dpkg -s proxmox-mailgateway-container >/dev/null 2>&1 &&
! dpkg -s proxmox-mailgateway >/dev/null 2>&1; then
if ! grep -q "Proxmox Mail Gateway" /etc/issue 2>/dev/null; then
msg_error "This script is only intended for Proxmox Mail Gateway"
exit 232
fi
@@ -58,24 +57,14 @@ repo_state() {
local repo="$1"
local file=""
local state="missing"
for f in /etc/apt/sources.list /etc/apt/sources.list.d/*.list /etc/apt/sources.list.d/*.sources; do
for f in /etc/apt/sources.list /etc/apt/sources.list.d/*.list; do
[[ -f "$f" ]] || continue
if grep -q "$repo" "$f"; then
file="$f"
if [[ "$f" == *.sources ]]; then
# deb822 format: check Enabled field
if grep -qiE '^Enabled:\s*no' "$f"; then
state="disabled"
else
state="active"
fi
else
# legacy format
if grep -qE "^[^#].*${repo}" "$f"; then
state="active"
elif grep -qE "^#.*${repo}" "$f"; then
state="disabled"
fi
if grep -qE "^[^#].*${repo}" "$f"; then
state="active"
elif grep -qE "^#.*${repo}" "$f"; then
state="disabled"
fi
break
fi
@@ -83,28 +72,6 @@ repo_state() {
echo "$state $file"
}
toggle_repo() {
# $1 = file, $2 = action (enable|disable)
local file="$1" action="$2"
if [[ "$file" == *.sources ]]; then
if [[ "$action" == "disable" ]]; then
if grep -qiE '^Enabled:' "$file"; then
sed -i 's/^Enabled:.*/Enabled: no/' "$file"
else
echo "Enabled: no" >>"$file"
fi
else
sed -i 's/^Enabled:.*/Enabled: yes/' "$file"
fi
else
if [[ "$action" == "disable" ]]; then
sed -i '/^[^#]/s/^/# /' "$file"
else
sed -i 's/^# *//' "$file"
fi
fi
}
start_routines() {
header_info
VERSION="$(awk -F'=' '/^VERSION_CODENAME=/{ print $NF }' /etc/os-release)"
@@ -117,20 +84,11 @@ start_routines() {
case $CHOICE in
yes)
msg_info "Correcting Debian Sources"
cat <<EOF >/etc/apt/sources.list.d/debian.sources
Types: deb
URIs: http://deb.debian.org/debian
Suites: ${VERSION} ${VERSION}-updates
Components: main contrib non-free non-free-firmware
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
Types: deb
URIs: http://security.debian.org/debian-security
Suites: ${VERSION}-security
Components: main contrib non-free non-free-firmware
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
cat <<EOF >/etc/apt/sources.list
deb http://deb.debian.org/debian ${VERSION} main contrib
deb http://deb.debian.org/debian ${VERSION}-updates main contrib
deb http://security.debian.org/debian-security ${VERSION}-security main contrib
EOF
rm -f /etc/apt/sources.list
msg_ok "Corrected Debian Sources"
;;
no) msg_error "Selected no to Correcting Debian Sources" ;;
@@ -150,7 +108,7 @@ EOF
keep) msg_ok "Kept 'pmg-enterprise' repository" ;;
disable)
msg_info "Disabling 'pmg-enterprise' repository"
toggle_repo "$file" disable
sed -i "s/^[^#].*pmg-enterprise/# &/" "$file"
msg_ok "Disabled 'pmg-enterprise' repository"
;;
delete)
@@ -170,7 +128,7 @@ EOF
case $CHOICE in
enable)
msg_info "Enabling 'pmg-enterprise' repository"
toggle_repo "$file" enable
sed -i "s/^#.*pmg-enterprise/deb/" "$file"
msg_ok "Enabled 'pmg-enterprise' repository"
;;
keep) msg_ok "Kept 'pmg-enterprise' repository disabled" ;;
@@ -191,12 +149,8 @@ EOF
case $CHOICE in
yes)
msg_info "Adding 'pmg-enterprise' repository"
cat >/etc/apt/sources.list.d/pmg-enterprise.sources <<EOF
Types: deb
URIs: https://enterprise.proxmox.com/debian/pmg
Suites: ${VERSION}
Components: pmg-enterprise
Signed-By: /etc/apt/keyrings/pmg.gpg
cat >/etc/apt/sources.list.d/pmg-enterprise.list <<EOF
deb https://enterprise.proxmox.com/debian/pmg ${VERSION} pmg-enterprise
EOF
msg_ok "Added 'pmg-enterprise' repository"
;;
@@ -219,7 +173,7 @@ EOF
keep) msg_ok "Kept 'pmg-no-subscription' repository" ;;
disable)
msg_info "Disabling 'pmg-no-subscription' repository"
toggle_repo "$file" disable
sed -i "s/^[^#].*pmg-no-subscription/# &/" "$file"
msg_ok "Disabled 'pmg-no-subscription' repository"
;;
delete)
@@ -239,7 +193,7 @@ EOF
case $CHOICE in
enable)
msg_info "Enabling 'pmg-no-subscription' repository"
toggle_repo "$file" enable
sed -i "s/^#.*pmg-no-subscription/deb/" "$file"
msg_ok "Enabled 'pmg-no-subscription' repository"
;;
keep) msg_ok "Kept 'pmg-no-subscription' repository disabled" ;;
@@ -259,12 +213,8 @@ EOF
case $CHOICE in
yes)
msg_info "Adding 'pmg-no-subscription' repository"
cat >/etc/apt/sources.list.d/pmg-no-subscription.sources <<EOF
Types: deb
URIs: http://download.proxmox.com/debian/pmg
Suites: ${VERSION}
Components: pmg-no-subscription
Signed-By: /etc/apt/keyrings/pmg.gpg
cat >/etc/apt/sources.list.d/pmg-install-repo.list <<EOF
deb http://download.proxmox.com/debian/pmg ${VERSION} pmg-no-subscription
EOF
msg_ok "Added 'pmg-no-subscription' repository"
;;
@@ -286,13 +236,8 @@ EOF
case $CHOICE in
yes)
msg_info "Adding 'pmgtest' repository (disabled)"
cat >/etc/apt/sources.list.d/pmgtest.sources <<EOF
Types: deb
URIs: http://download.proxmox.com/debian/pmg
Suites: ${VERSION}
Components: pmgtest
Signed-By: /etc/apt/keyrings/pmg.gpg
Enabled: no
cat >/etc/apt/sources.list.d/pmgtest-for-beta.list <<EOF
# deb http://download.proxmox.com/debian/pmg ${VERSION} pmgtest
EOF
msg_ok "Added 'pmgtest' repository"
;;