refactor: simplify file ownership in the container by setting the process ownership during the build process
Rather than require a heavy chown operation across various paths, just chown the files already in the built image during the release process. This ensures we can skip not-only the chown process during the container start that herokuish injects, but also the one that Dokku runs which modifies mounted container paths as well during the pre-deploy. Note that users will need to ensure any mounted volumes don't have permissions reset by other processes or containers won't be able to access them.
This commit is contained in:
1 parent
0d6bde2eff
commit
68d05b230d
12 files changed
+20
-83
No files matched your search
@@ -9,13 +9,13 @@ cmd-scheduler-docker-local-set() {
|
||||
declare cmd="scheduler-docker-local:set"
|
||||
[[ "$1" == "$cmd" ]] && shift 1
|
||||
declare APP="$1" KEY="$2" VALUE="$3"
|
||||
local VALID_KEYS=("disable-chown" "init-process" "parallel-schedule-count")
|
||||
local VALID_KEYS=("init-process" "parallel-schedule-count")
|
||||
verify_app_name "$APP"
|
||||
|
||||
[[ -z "$KEY" ]] && dokku_log_fail "No key specified"
|
||||
|
||||
if ! fn-in-array "$KEY" "${VALID_KEYS[@]}"; then
|
||||
dokku_log_fail "Invalid key specified, valid keys include: disable-chown, init-process, parallel-schedule-count"
|
||||
dokku_log_fail "Invalid key specified, valid keys include: init-process, parallel-schedule-count"
|
||||
fi
|
||||
|
||||
if [[ -n "$VALUE" ]]; then
|
||||
|
||||
Reference in new issue
Block a user