这是indexloc提供的服务,不要输入任何密码
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 35 additions & 30 deletions dokku
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
source "$PLUGIN_CORE_AVAILABLE_PATH/checks/functions"
source "$PLUGIN_CORE_AVAILABLE_PATH/proxy/functions"

[[ -f $DOKKU_ROOT/dokkurc ]] && source $DOKKU_ROOT/dokkurc
[[ -d $DOKKU_ROOT/.dokkurc ]] && for f in $DOKKU_ROOT/.dokkurc/*; do source $f; done
[[ -f $DOKKU_ROOT/dokkurc ]] && source "$DOKKU_ROOT/dokkurc"
[[ -d $DOKKU_ROOT/.dokkurc ]] && for f in $DOKKU_ROOT/.dokkurc/*; do source "$f"; done

[[ $DOKKU_TRACE ]] && set -x

Expand All @@ -56,7 +56,7 @@ fi

if [[ $(id -un) != "dokku" ]] && [[ ! $1 =~ plugin:* ]]; then
export SSH_USER=$(id -un)
sudo -u dokku -E -H $0 "$@"
sudo -u dokku -E -H "$0" "$@"
exit $?
fi

Expand All @@ -67,10 +67,12 @@ fi
if [[ -n "$SSH_ORIGINAL_COMMAND" ]]; then
export -n SSH_ORIGINAL_COMMAND
if [[ $1 =~ config-* ]] || [[ $1 =~ docker-options* ]]; then
# shellcheck disable=SC2086
xargs $0 <<<$SSH_ORIGINAL_COMMAND
exit $?
else
set -f
# shellcheck disable=SC2086
$0 $SSH_ORIGINAL_COMMAND
set +f
exit $?
Expand All @@ -84,7 +86,7 @@ fi

case "$1" in
receive)
APP="$2"; IMAGE=$(get_app_image_name $APP); IMAGE_SOURCE_TYPE="$3"; TMP_WORK_DIR="$4"
APP="$2"; IMAGE=$(get_app_image_name "$APP"); IMAGE_SOURCE_TYPE="$3"; TMP_WORK_DIR="$4"
if [[ -z "$DOKKU_SKIP_CLEANUP" ]]; then
dokku_log_info1 "Cleaning up..."
docker_cleanup
Expand All @@ -98,16 +100,16 @@ case "$1" in

deploy)
[[ -z $2 ]] && dokku_log_fail "Please specify an app to deploy"
APP="$2"; IMAGE_TAG="$3"; IMAGE=$(get_app_image_name $APP $IMAGE_TAG)
APP="$2"; IMAGE_TAG="$3"; IMAGE=$(get_app_image_name "$APP" "$IMAGE_TAG")
verify_app_name "$APP"
plugn trigger pre-deploy $APP $IMAGE_TAG
plugn trigger pre-deploy "$APP" "$IMAGE_TAG"

is_image_herokuish_based "$IMAGE" && DOKKU_HEROKUISH=true
DOKKU_SCALE_FILE="$DOKKU_ROOT/$APP/DOKKU_SCALE"
oldids=$(get_app_container_ids $APP)
oldids=$(get_app_container_ids "$APP")

DOKKU_DEFAULT_DOCKER_ARGS=$(: | plugn trigger docker-args-deploy $APP $IMAGE_TAG)
DOKKU_IS_APP_PROXY_ENABLED="$(is_app_proxy_enabled $APP)"
DOKKU_DEFAULT_DOCKER_ARGS=$(: | plugn trigger docker-args-deploy "$APP" "$IMAGE_TAG")
DOKKU_IS_APP_PROXY_ENABLED="$(is_app_proxy_enabled "$APP")"

while read -r line || [[ -n "$line" ]]; do
[[ "$line" =~ ^#.* ]] && continue
Expand All @@ -130,10 +132,10 @@ case "$1" in
[[ -n "$DOKKU_HEROKUISH" ]] && START_CMD="/start $PROC_TYPE"

if [[ -z "$DOKKU_HEROKUISH" ]]; then
DOKKU_DOCKERFILE_PORTS=($(dokku config:get $APP DOKKU_DOCKERFILE_PORTS || true))
DOKKU_DOCKERFILE_PORT=$(dokku config:get $APP DOKKU_DOCKERFILE_PORT || true)
DOKKU_DOCKERFILE_START_CMD=$(dokku config:get $APP DOKKU_DOCKERFILE_START_CMD || true)
DOKKU_PROCFILE_START_CMD=$(get_cmd_from_procfile $APP $PROC_TYPE)
DOKKU_DOCKERFILE_PORTS=($(dokku config:get "$APP" DOKKU_DOCKERFILE_PORTS || true))
DOKKU_DOCKERFILE_PORT=$(dokku config:get "$APP" DOKKU_DOCKERFILE_PORT || true)
DOKKU_DOCKERFILE_START_CMD=$(dokku config:get "$APP" DOKKU_DOCKERFILE_START_CMD || true)
DOKKU_PROCFILE_START_CMD=$(get_cmd_from_procfile "$APP" "$PROC_TYPE")
START_CMD=${DOKKU_DOCKERFILE_START_CMD:-$DOKKU_PROCFILE_START_CMD}
fi

Expand All @@ -152,45 +154,48 @@ case "$1" in
done
fi
if [[ "$DOKKU_IS_APP_PROXY_ENABLED" = "true" ]]; then
# shellcheck disable=SC2086
id=$(docker run $DOKKU_GLOBAL_RUN_ARGS -d -e PORT=$port $DOCKER_ARGS $IMAGE $START_CMD)
ipaddr=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $id)
ipaddr=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' "$id")
# Docker < 1.9 compatibility
if [[ -z $ipaddr ]]; then
ipaddr=$(docker inspect --format '{{ .NetworkSettings.IPAddress }}' $id)
ipaddr=$(docker inspect --format '{{ .NetworkSettings.IPAddress }}' "$id")
fi
else
# shellcheck disable=SC2086
id=$(docker run $DOKKU_GLOBAL_RUN_ARGS -d $DOKKU_DOCKER_PORT_ARGS -e PORT=$port $DOCKER_ARGS $IMAGE $START_CMD)
port=$(docker port $id $port | sed 's/[0-9.]*://')
port=$(docker port "$id" "$port" | sed 's/[0-9.]*://')
ipaddr=127.0.0.1
fi
else
# shellcheck disable=SC2086
id=$(docker run $DOKKU_GLOBAL_RUN_ARGS -d $DOCKER_ARGS $IMAGE $START_CMD)
fi

# if we can't post-deploy successfully, kill new container
kill_new() {
docker inspect $id &> /dev/null && docker stop $id > /dev/null && docker kill $id > /dev/null
docker inspect "$id" &> /dev/null && docker stop "$id" > /dev/null && docker kill "$id" > /dev/null
trap - INT TERM EXIT
kill -9 $$
}

# run checks first, then post-deploy hooks, which switches Nginx traffic
if [[ "$(is_app_checks_enabled $APP)" == "false" ]]; then
if [[ "$(is_app_checks_enabled "$APP")" == "false" ]]; then
dokku_log_info1 "zero downtime is disabled for app ($APP). skipping pre-flight checks"
else
trap kill_new INT TERM EXIT
dokku_log_info1 "Running pre-flight checks"
plugn trigger check-deploy $APP $id $PROC_TYPE $port $ipaddr
plugn trigger check-deploy "$APP" "$id" "$PROC_TYPE" "$port" "$ipaddr"
trap - INT TERM EXIT
fi

# now using the new container
[[ -n "$id" ]] && echo $id > "$DOKKU_CONTAINER_ID_FILE"
[[ -n "$ipaddr" ]] && echo $ipaddr > "$DOKKU_IP_FILE"
[[ -n "$port" ]] && echo $port > "$DOKKU_PORT_FILE"
[[ -n "$id" ]] && echo "$id" > "$DOKKU_CONTAINER_ID_FILE"
[[ -n "$ipaddr" ]] && echo "$ipaddr" > "$DOKKU_IP_FILE"
[[ -n "$port" ]] && echo "$port" > "$DOKKU_PORT_FILE"

# cleanup pre-migration files
rm -f $DOKKU_ROOT/$APP/CONTAINER $DOKKU_ROOT/$APP/IP $DOKKU_ROOT/$APP/PORT
rm -f "$DOKKU_ROOT/$APP/CONTAINER" "$DOKKU_ROOT/$APP/IP" "$DOKKU_ROOT/$APP/PORT"

CONTAINER_INDEX=$(( CONTAINER_INDEX + 1 ))
done
Expand All @@ -201,19 +206,19 @@ case "$1" in
CONTAINER_IDX_OFFSET=$((PROC_COUNT + 1))
fi
for container_state_filetype in CONTAINER IP PORT; do
cd $DOKKU_ROOT/$APP
cd "$DOKKU_ROOT/$APP"
find . -maxdepth 1 -name "$container_state_filetype.$PROC_TYPE.*" -printf "%f\n" | sort -t . -k 3 -n | tail -n +$CONTAINER_IDX_OFFSET | xargs rm -f
done
done < "$DOKKU_SCALE_FILE"

dokku_log_info1 "Running post-deploy"
plugn trigger post-deploy $APP $port $ipaddr $IMAGE_TAG
plugn trigger post-deploy "$APP" "$port" "$ipaddr" "$IMAGE_TAG"

# kill the old container
if [[ -n "$oldids" ]]; then

if [[ -z "$DOKKU_WAIT_TO_RETIRE" ]]; then
DOKKU_APP_DOKKU_WAIT_TO_RETIRE=$(dokku config:get $APP DOKKU_WAIT_TO_RETIRE || true)
DOKKU_APP_DOKKU_WAIT_TO_RETIRE=$(dokku config:get "$APP" DOKKU_WAIT_TO_RETIRE || true)
DOKKU_GLOBAL_DOKKU_WAIT_TO_RETIRE=$(dokku config:get --global DOKKU_WAIT_TO_RETIRE || true)
DOKKU_WAIT_TO_RETIRE=${DOKKU_APP_DOKKU_WAIT_TO_RETIRE:="$DOKKU_GLOBAL_DOKKU_WAIT_TO_RETIRE"}
fi
Expand All @@ -227,14 +232,14 @@ case "$1" in
(
exec >/dev/null 2>/dev/null </dev/null
trap '' INT HUP
sleep $WAIT
sleep "$WAIT"
for oldid in $oldids; do
# Attempt to stop, if that fails, then force a kill as docker seems
# to not send SIGKILL as the docs would indicate. If that fails, move
# on to the next.
docker stop $oldid \
|| docker kill $oldid \
|| plugn trigger retire-container-failed $APP # plugin trigger for event logging
docker stop "$oldid" \
|| docker kill "$oldid" \
|| plugn trigger retire-container-failed "$APP" # plugin trigger for event logging
done
) & disown -a
# Use trap since disown/nohup don't seem to keep child alive
Expand Down
2 changes: 1 addition & 1 deletion plugins/00_dokku-standard/backup-check
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -eo pipefail; [[ $DOKKU_TRACE ]] && set -x
VERSION="$1"
IMPORT_DIR="$2"
TARGET_DIR="$3"
APPS="$(< $4 )"
APPS="$(< "$4" )"

ret=0

Expand Down
14 changes: 7 additions & 7 deletions plugins/00_dokku-standard/backup-import
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ VERSION="$1"
IMPORT_DIR="$2"
TARGET_DIR="$3"

[[ -f $IMPORT_DIR/.sshcommand ]] && mv $IMPORT_DIR/.sshcommand $TARGET_DIR/.sshcommand
[[ -f $IMPORT_DIR/.sshcommand ]] && mv "$IMPORT_DIR/.sshcommand" "$TARGET_DIR/.sshcommand"
if [[ -f $IMPORT_DIR/.ssh/authorized_keys ]]; then
mkdir -p $TARGET_DIR/.ssh
cat $IMPORT_DIR/.ssh/authorized_keys $TARGET_DIR/.ssh/authorized_keys | uniq > tmpfile && mv tmpfile $TARGET_DIR/.ssh/authorized_keys
chmod 0700 $TARGET_DIR/.ssh
chmod 0600 $TARGET_DIR/.ssh/*
mkdir -p "$TARGET_DIR/.ssh"
cat "$IMPORT_DIR/.ssh/authorized_keys" "$TARGET_DIR/.ssh/authorized_keys" | uniq > tmpfile && mv tmpfile "$TARGET_DIR/.ssh/authorized_keys"
chmod 0700 "$TARGET_DIR/.ssh"
chmod 0600 "$TARGET_DIR"/.ssh/*
fi
[[ -f $IMPORT_DIR/HOSTNAME ]] && mv $IMPORT_DIR/HOSTNAME $TARGET_DIR/HOSTNAME
[[ -f $IMPORT_DIR/VHOST ]] && mv $IMPORT_DIR/VHOST $TARGET_DIR/VHOST
[[ -f $IMPORT_DIR/HOSTNAME ]] && mv "$IMPORT_DIR/HOSTNAME" "$TARGET_DIR/HOSTNAME"
[[ -f $IMPORT_DIR/VHOST ]] && mv "$IMPORT_DIR/VHOST" "$TARGET_DIR/VHOST"
70 changes: 36 additions & 34 deletions plugins/00_dokku-standard/commands
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/usr/bin/env bash
[[ " build release trace delete ls run url urls report version help " == *" $1 "* ]] || exit $DOKKU_NOT_IMPLEMENTED_EXIT
[[ " build release trace delete ls run url urls report version help " == *" $1 "* ]] || exit "$DOKKU_NOT_IMPLEMENTED_EXIT"
set -eo pipefail; [[ $DOKKU_TRACE ]] && set -x
source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
source "$PLUGIN_AVAILABLE_PATH/config/functions"
Expand All @@ -8,41 +8,43 @@ source "$PLUGIN_CORE_AVAILABLE_PATH/proxy/functions"

case "$1" in
build)
APP="$2"; IMAGE_SOURCE_TYPE="$3"; TMP_WORK_DIR="$4"; IMAGE=$(get_app_image_name $APP)
APP="$2"; IMAGE_SOURCE_TYPE="$3"; TMP_WORK_DIR="$4"; IMAGE=$(get_app_image_name "$APP")
verify_app_name "$APP"

CACHE_DIR="$DOKKU_ROOT/$APP/cache"

eval "$(config_export app $APP)"
eval "$(config_export app "$APP")"
pushd "$TMP_WORK_DIR" &> /dev/null

case "$IMAGE_SOURCE_TYPE" in
herokuish)
id=$(tar -c . | docker run $DOKKU_GLOBAL_RUN_ARGS -i -a stdin $DOKKU_IMAGE /bin/bash -c "mkdir -p /app && tar -xC /app")
test "$(docker wait $id)" -eq 0
docker commit $id $IMAGE > /dev/null
[[ -d $CACHE_DIR ]] || mkdir $CACHE_DIR
id=$(tar -c . | docker run "$DOKKU_GLOBAL_RUN_ARGS" -i -a stdin "$DOKKU_IMAGE" /bin/bash -c "mkdir -p /app && tar -xC /app")
test "$(docker wait "$id")" -eq 0
docker commit "$id" "$IMAGE" > /dev/null
[[ -d $CACHE_DIR ]] || mkdir "$CACHE_DIR"
plugn trigger pre-build-buildpack "$APP"

DOCKER_ARGS=$(: | plugn trigger docker-args-build $APP $IMAGE_SOURCE_TYPE)
DOCKER_ARGS=$(: | plugn trigger docker-args-build "$APP" "$IMAGE_SOURCE_TYPE")
[[ "$DOKKU_TRACE" ]] && DOCKER_ARGS+=" -e TRACE=true "
# shellcheck disable=SC2086
id=$(docker run $DOKKU_GLOBAL_RUN_ARGS -d -v $CACHE_DIR:/cache -e CACHE_PATH=/cache $DOCKER_ARGS $IMAGE /build)
docker attach $id
test "$(docker wait $id)" -eq 0
docker commit $id $IMAGE > /dev/null
docker attach "$id"
test "$(docker wait "$id")" -eq 0
docker commit "$id" "$IMAGE" > /dev/null

plugn trigger post-build-buildpack "$APP"
;;

dockerfile)
# extract first port from Dockerfile
DOCKERFILE_PORTS=$(get_dockerfile_exposed_ports Dockerfile)
[[ -n "$DOCKERFILE_PORTS" ]] && config_set --no-restart $APP DOKKU_DOCKERFILE_PORTS="$DOCKERFILE_PORTS"
[[ -n "$DOCKERFILE_PORTS" ]] && config_set --no-restart "$APP" DOKKU_DOCKERFILE_PORTS="$DOCKERFILE_PORTS"
plugn trigger pre-build-dockerfile "$APP"

[[ "$DOKKU_DOCKERFILE_CACHE_BUILD" == "false" ]] && DOKKU_DOCKER_BUILD_OPTS="$DOKKU_DOCKER_BUILD_OPTS --no-cache"
DOCKER_ARGS=$(: | plugn trigger docker-args-build $APP $IMAGE_SOURCE_TYPE)
docker build $DOCKER_ARGS $DOKKU_DOCKER_BUILD_OPTS -t "$IMAGE" .
DOCKER_ARGS=$(: | plugn trigger docker-args-build "$APP" "$IMAGE_SOURCE_TYPE")
# shellcheck disable=SC2086
docker build $DOCKER_ARGS $DOKKU_DOCKER_BUILD_OPTS -t $IMAGE .

plugn trigger post-build-dockerfile "$APP"
;;
Expand All @@ -54,21 +56,21 @@ case "$1" in
;;

release)
APP="$2"; IMAGE_SOURCE_TYPE="$3"; IMAGE_TAG="$4"; IMAGE=$(get_app_image_name $APP $IMAGE_TAG)
APP="$2"; IMAGE_SOURCE_TYPE="$3"; IMAGE_TAG="$4"; IMAGE=$(get_app_image_name "$APP" "$IMAGE_TAG")
verify_app_name "$APP"

case "$IMAGE_SOURCE_TYPE" in
herokuish)
plugn trigger pre-release-buildpack "$APP" "$IMAGE_TAG"
if [[ -n $(config_export global) ]]; then
id=$(config_export global | docker run $DOKKU_GLOBAL_RUN_ARGS -i -a stdin $IMAGE /bin/bash -c "mkdir -p /app/.profile.d && cat > /app/.profile.d/00-global-env.sh")
test "$(docker wait $id)" -eq 0
docker commit $id $IMAGE > /dev/null
id=$(config_export global | docker run "$DOKKU_GLOBAL_RUN_ARGS" -i -a stdin "$IMAGE" /bin/bash -c "mkdir -p /app/.profile.d && cat > /app/.profile.d/00-global-env.sh")
test "$(docker wait "$id")" -eq 0
docker commit "$id" "$IMAGE" > /dev/null
fi
if [[ -n $(config_export app $APP) ]]; then
id=$(config_export app $APP | docker run $DOKKU_GLOBAL_RUN_ARGS -i -a stdin $IMAGE /bin/bash -c "mkdir -p /app/.profile.d && cat > /app/.profile.d/01-app-env.sh")
test "$(docker wait $id)" -eq 0
docker commit $id $IMAGE > /dev/null
if [[ -n $(config_export app "$APP") ]]; then
id=$(config_export app "$APP" | docker run "$DOKKU_GLOBAL_RUN_ARGS" -i -a stdin "$IMAGE" /bin/bash -c "mkdir -p /app/.profile.d && cat > /app/.profile.d/01-app-env.sh")
test "$(docker wait "$id")" -eq 0
docker commit "$id" "$IMAGE" > /dev/null
fi
plugn trigger post-release-buildpack "$APP" "$IMAGE_TAG"
;;
Expand All @@ -86,24 +88,24 @@ case "$1" in
;;

trace)
[[ -d $DOKKU_ROOT/.dokkurc ]] || mkdir -p $DOKKU_ROOT/.dokkurc
[[ -d $DOKKU_ROOT/.dokkurc ]] || mkdir -p "$DOKKU_ROOT/.dokkurc"
[[ "$2" == "on" ]] || [[ "$2" == "off" ]] || {
dokku_log_fail "Valid trace options are [on/off]"
}

if [[ "$2" == "on" ]]; then
echo "Enabling dokku trace"
echo "export DOKKU_TRACE=1" > $DOKKU_ROOT/.dokkurc/DOKKU_TRACE
echo "export DOKKU_TRACE=1" > "$DOKKU_ROOT/.dokkurc/DOKKU_TRACE"
fi

if [[ "$2" == "off" ]]; then
echo "Disabling dokku trace"
rm -f $DOKKU_ROOT/.dokkurc/DOKKU_TRACE
rm -f "$DOKKU_ROOT/.dokkurc/DOKKU_TRACE"
fi
;;

delete)
dokku apps:destroy $2
dokku apps:destroy "$2"
;;

ls)
Expand All @@ -112,14 +114,14 @@ case "$1" in
dokku_col_log_info1_quiet "App Name" "Container Type" "Container Id" "Status"

for dokku_app in $installed_apps; do
APP=$(basename $dokku_app)
DOKKU_APP_CIDS=$(get_app_container_ids $APP)
APP=$(basename "$dokku_app")
DOKKU_APP_CIDS=$(get_app_container_ids "$APP")
DOCKER_RUNNING_CONTAINERS=$(docker ps -q --no-trunc)
if [[ -n $DOKKU_APP_CIDS ]]; then
for DOKKU_APP_CID in $DOKKU_APP_CIDS; do
DOKKU_APP_CONTAINER_STATUS="stopped"
[[ $DOCKER_RUNNING_CONTAINERS =~ $DOKKU_APP_CID ]] && DOKKU_APP_CONTAINER_STATUS="running"
DOKKU_APP_CONTAINER_TYPE=$(grep -l $DOKKU_APP_CID $DOKKU_ROOT/$APP/CONTAINER.* | awk -F '/' '{ print $5 }' | awk -F '.' '{ print $2 }')
DOKKU_APP_CONTAINER_TYPE=$(grep -l "$DOKKU_APP_CID" "$DOKKU_ROOT/$APP"/CONTAINER.* | awk -F '/' '{ print $5 }' | awk -F '.' '{ print $2 }')
dokku_col_log_msg "$APP" "$DOKKU_APP_CONTAINER_TYPE" "${DOKKU_APP_CID:0:12}" "$DOKKU_APP_CONTAINER_STATUS"
done
else
Expand All @@ -130,23 +132,23 @@ case "$1" in

run)
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
APP="$2"; IMAGE_TAG=$(get_running_image_tag $APP); IMAGE=$(get_app_image_name $APP $IMAGE_TAG)
APP="$2"; IMAGE_TAG=$(get_running_image_tag "$APP"); IMAGE=$(get_app_image_name "$APP" "$IMAGE_TAG")
verify_app_name "$APP"

shift 2

if [[ -z "$DOKKU_RM_CONTAINER" ]]; then
DOKKU_APP_RM_CONTAINER=$(dokku config:get $APP DOKKU_RM_CONTAINER || true)
DOKKU_APP_RM_CONTAINER=$(dokku config:get "$APP" DOKKU_RM_CONTAINER || true)
DOKKU_GLOBAL_RM_CONTAINER=$(dokku config:get --global DOKKU_RM_CONTAINER || true)
DOKKU_RM_CONTAINER=${DOKKU_APP_RM_CONTAINER:="$DOKKU_GLOBAL_RM_CONTAINER"}
fi

DOCKER_ARGS=$(: | plugn trigger docker-args-run $APP $IMAGE_TAG)
DOCKER_ARGS=$(: | plugn trigger docker-args-run "$APP" "$IMAGE_TAG")
[[ "$DOKKU_TRACE" ]] && DOCKER_ARGS+=" -e TRACE=true "
[[ "$DOKKU_RM_CONTAINER" ]] && DOKKU_RUN_OPTS="--rm"
has_tty && DOKKU_RUN_OPTS+=" -i -t"
is_image_herokuish_based "$IMAGE" && EXEC_CMD="/exec"

# shellcheck disable=SC2086
docker run $DOKKU_GLOBAL_RUN_ARGS $DOKKU_RUN_OPTS $DOCKER_ARGS $IMAGE $EXEC_CMD "$@"
;;

Expand Down Expand Up @@ -187,7 +189,7 @@ EOF
;;

*)
exit $DOKKU_NOT_IMPLEMENTED_EXIT
exit "$DOKKU_NOT_IMPLEMENTED_EXIT"
;;

esac
Loading