fix: handle case in ubuntu 16.04 where popd may fail if the dokku user does not have rights to execute in the executing user's $PWD.
Closes #2978
This commit is contained in:
@@ -23,7 +23,7 @@ apps_clone_cmd() {
|
||||
apps_create "$NEW_APP"
|
||||
pushd "$DOKKU_ROOT/$OLD_APP/." > /dev/null
|
||||
find ./* -not \( -name .cache \) | grep -v "./cache" | cpio -pdmu --quiet "$DOKKU_ROOT/$NEW_APP"
|
||||
popd > /dev/null
|
||||
popd > /dev/null 2>&1 || pushd "/tmp" > /dev/null
|
||||
|
||||
if [[ -d "$NEW_CACHE_DIR" ]] && ! rmdir "$NEW_CACHE_DIR"; then
|
||||
docker run "$DOKKU_GLOBAL_RUN_ARGS" --rm -v "$NEW_CACHE_DIR:/cache" "dokku/$OLD_APP" chmod 777 -R /cache
|
||||
|
||||
Reference in New Issue
Block a user