During app update, copy remaining app files before the app is started (#174)

Co-authored-by: Steven Briscoe <[email protected]>
This commit is contained in:
Steven Briscoe
2023-01-27 12:46:11 +00:00
committed by Steven Briscoe
co-authored by Steven Briscoe
parent a023b3db1c
commit 73f99fa7ac
+4 -1
View File
@@ -554,7 +554,7 @@ if [[ "$command" = "update" ]]; then
copy_app_files "${UPDATE_FILES_WHITELIST_PRE}"
# Copy remaining files in the event of error or success
# Ensure remaining files are copied in case of unexpected exit
trap "copy_app_files "${UPDATE_FILES_WHITELIST_POST}"; exit $?" INT TERM EXIT
# Source env. after new exports.sh is copied (done above via 'copy_app_files')
@@ -566,6 +566,9 @@ if [[ "$command" = "update" ]]; then
echo "Pulling images for app ${app}..."
compose "${app}" pull
# Copy remaining files to mark update as complete
copy_app_files "${UPDATE_FILES_WHITELIST_POST}"
if [[ "$*" != *"--skip-start"* ]]; then
"${0}" "start" "${app}"
# Remove any old images we don't need anymore