Skip to content
This repository was archived by the owner on Jan 25, 2022. It is now read-only.

Commit bc3025f

Browse files
committed
Fixing mistaken use of chmod to chown
1 parent f27723d commit bc3025f

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

cli/includes/functions

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ export BOX_WATCHERS_DIR="${BOX_WEB_ROOT_DIR}/watchers"
3636
export BOX_PHPCLI=${BOX_BASE_DIR}/bin/php
3737
export BOX_CACHE_DIR="/tmp/box-cache"
3838
mkdir -p "${BOX_CACHE_DIR}"
39+
sudo chown --silent --preserve-root --recursive "${BOX_USER}:${BOX_USER}" "${BOX_CACHE_DIR}"
3940

4041
export BOX_GIT_DIR="${BOX_BASE_DIR}/.git"
4142
export BOX_LOGS_DIR="${BOX_PROJECT_DIR}/logs"
@@ -59,10 +60,12 @@ export BOX_SCRIPTS_REPO="https://github.com/wplib/box-scripts/"
5960

6061
export BOX_DEPLOY_LOCK_SLUG="deploy-lock"
6162

62-
mkdir -p /tmp/box-tmp
63-
export DEPLOY_LOG="/tmp/box-tmp/deploy.log"
64-
rm -rf "${DEPLOY_LOG}"
65-
touch "${DEPLOY_LOG}"
63+
export BOX_TMP_DIR="/tmp/box-tmp"
64+
mkdir -p "${BOX_TMP_DIR}"
65+
sudo chown --silent --preserve-root --recursive "${BOX_USER}:${BOX_USER}" "${BOX_TMP_DIR}"
66+
export DEPLOY_LOG="${BOX_TMP_DIR}/deploy.log"
67+
sudo rm -rf "${DEPLOY_LOG}"
68+
touch "${DEPLOY_LOG}"
6669

6770
source ${BOX_INCLUDES_DIR}/colors
6871

0 commit comments

Comments
 (0)