feat: inject the dokku PID into temporary files/directories
This will allow background processes to cleanup these files if they were unable to be cleaned up during a run of the dokku binary, as is the case for files copied by the docker binary when running in docker.
This commit is contained in:
@@ -31,7 +31,7 @@ git_build_app_repo() {
|
||||
verify_app_name "$APP"
|
||||
|
||||
# clean up after ourselves
|
||||
local GIT_BUILD_APP_REPO_TMP_WORK_DIR=$(mktemp -d "/tmp/dokku-${FUNCNAME[0]}.XXXX")
|
||||
local GIT_BUILD_APP_REPO_TMP_WORK_DIR=$(mktemp -d "/tmp/dokku-${DOKKU_PID}-${FUNCNAME[0]}.XXXX")
|
||||
trap "rm -rf '$GIT_BUILD_APP_REPO_TMP_WORK_DIR' >/dev/null" RETURN INT TERM EXIT
|
||||
|
||||
local TMP_TAG="dokku/$REV"
|
||||
|
||||
Reference in New Issue
Block a user