feat: write current process id to all acquired lock files

This allows us to check on what process created a lock.

Additionally, we now always have a DOKKU_PID value, even when running in cron (which does not have access to BASH_PID.
This commit is contained in:
Jose Diaz-Gonzalez
2024-03-14 05:54:37 -04:00
parent 5553da1be1
commit 83b89453a5
3 changed files with 3 additions and 2 deletions

View File

@@ -983,6 +983,7 @@ acquire_advisory_lock() {
dokku_log_fail "Run 'apps:unlock' to release the existing deploy lock"
fi
fi
echo "$DOKKU_PID" >"$LOCK_FILE"
}
release_advisory_lock() {