mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-04-24 19:30:40 +00:00
core: remove unused TEMP_DIR mktemp leak in build_container / clean sonarqube (#13708)
* fix(core): remove unused TEMP_DIR mktemp leak in build_container The build_container() function created a temp directory via mktemp -d and pushd into it, but never popd or rm -rf. The directory was not used for anything — FUNCTIONS_FILE_PATH is downloaded into a variable, not a file. Remove the mktemp -d and pushd entirely to eliminate the leak. * fix(sonarqube): clean up temp file after zip extraction The SonarQube update function (ct/sonarqube.sh) never deleted the downloaded zip file (~200-500 MB) from /tmp after extraction. On LXC containers with 4-8 GB disks, this accumulates with every update and can eventually fill the disk. Also add explicit cleanup in the install script instead of relying solely on cleanup_lxc() pattern matching.
This commit is contained in:
committed by
GitHub
parent
482f579dc0
commit
e55fe43e2d
@@ -3613,8 +3613,6 @@ build_container() {
|
||||
fi
|
||||
|
||||
# Build PCT_OPTIONS as string for export
|
||||
TEMP_DIR=$(mktemp -d)
|
||||
pushd "$TEMP_DIR" >/dev/null
|
||||
local _func_url
|
||||
if [ "$var_os" == "alpine" ]; then
|
||||
_func_url="https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/alpine-install.func"
|
||||
|
||||
Reference in New Issue
Block a user