initial pass at switching to plugn
This commit is contained in:
committed by
Jose Diaz-Gonzalez
parent
ac75c726ad
commit
7a545759f2
@@ -19,39 +19,39 @@ case "$1" in
|
||||
test "$(docker wait $id)" -eq 0
|
||||
docker commit $id $IMAGE > /dev/null
|
||||
[[ -d $CACHE_DIR ]] || mkdir $CACHE_DIR
|
||||
# *DEPRECATED* in v0.3.15: `pluginhook pre-build` will be removed in future releases
|
||||
pluginhook pre-build "$APP"
|
||||
# *DEPRECATED* in v0.3.22: `pluginhook pre-build-buildstep` will be removed in future releases
|
||||
pluginhook pre-build-buildstep "$APP"
|
||||
pluginhook pre-build-buildpack "$APP"
|
||||
# *DEPRECATED* in v0.3.15: `plugn trigger pre-build` will be removed in future releases
|
||||
plugn trigger pre-build "$APP"
|
||||
# *DEPRECATED* in v0.3.22: `plugn trigger pre-build-buildstep` will be removed in future releases
|
||||
plugn trigger pre-build-buildstep "$APP"
|
||||
plugn trigger pre-build-buildpack "$APP"
|
||||
|
||||
# *DEPRECATED* in v0.3.14: `pluginhook docker-args` will be removed in future releases
|
||||
# *DEPRECATED* in v0.3.14: `plugn trigger docker-args` will be removed in future releases
|
||||
# https://github.com/progrium/dokku/issues/896 & https://github.com/progrium/dokku/issues/906
|
||||
DOCKER_ARGS=$(: | pluginhook docker-args $APP build)
|
||||
DOCKER_ARGS+=$(: | pluginhook docker-args-build $APP)
|
||||
DOCKER_ARGS=$(: | plugn trigger docker-args $APP build)
|
||||
DOCKER_ARGS+=$(: | plugn trigger docker-args-build $APP)
|
||||
[[ "$DOKKU_TRACE" ]] && DOCKER_ARGS+=" -e TRACE=true "
|
||||
id=$(docker run -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
|
||||
|
||||
# *DEPRECATED* in v0.3.15: `pluginhook post-build` will be removed in future releases
|
||||
pluginhook post-build "$APP"
|
||||
# *DEPRECATED* in v0.3.22: `pluginhook post-build-buildstep` will be removed in future releases
|
||||
pluginhook post-build-buildstep "$APP"
|
||||
pluginhook post-build-buildpack "$APP"
|
||||
# *DEPRECATED* in v0.3.15: `plugn trigger post-build` will be removed in future releases
|
||||
plugn trigger post-build "$APP"
|
||||
# *DEPRECATED* in v0.3.22: `plugn trigger post-build-buildstep` will be removed in future releases
|
||||
plugn trigger post-build-buildstep "$APP"
|
||||
plugn trigger post-build-buildpack "$APP"
|
||||
;;
|
||||
|
||||
dockerfile)
|
||||
# extract first port from Dockerfile
|
||||
DOCKERFILE_PORT=$(get_dockerfile_exposed_port Dockerfile)
|
||||
[[ -n "$DOCKERFILE_PORT" ]] && config_set --no-restart $APP DOKKU_DOCKERFILE_PORT=$DOCKERFILE_PORT
|
||||
pluginhook pre-build-dockerfile "$APP"
|
||||
plugn trigger pre-build-dockerfile "$APP"
|
||||
|
||||
[[ "$DOKKU_DOCKERFILE_CACHE_BUILD" == "false" ]] && DOKKU_DOCKER_BUILD_OPTS="$DOKKU_DOCKER_BUILD_OPTS --no-cache"
|
||||
docker build $DOKKU_DOCKER_BUILD_OPTS -t "$IMAGE" .
|
||||
|
||||
pluginhook post-build-dockerfile "$APP"
|
||||
plugn trigger post-build-dockerfile "$APP"
|
||||
;;
|
||||
|
||||
*)
|
||||
@@ -66,11 +66,11 @@ case "$1" in
|
||||
|
||||
case "$IMAGE_SOURCE_TYPE" in
|
||||
herokuish)
|
||||
# *DEPRECATED* in v0.3.15: `pluginhook pre-release` will be removed in future releases
|
||||
pluginhook pre-release $APP $IMAGE_TAG
|
||||
# *DEPRECATED* in v0.3.22: `pluginhook pre-release-buildstep` will be removed in future releases
|
||||
pluginhook pre-release-buildstep $APP $IMAGE_TAG
|
||||
pluginhook pre-release-buildpack $APP $IMAGE_TAG
|
||||
# *DEPRECATED* in v0.3.15: `plugn trigger pre-release` will be removed in future releases
|
||||
plugn trigger pre-release "$APP" "$IMAGE_TAG"
|
||||
# *DEPRECATED* in v0.3.22: `plugn trigger pre-release-buildstep` will be removed in future releases
|
||||
plugn trigger pre-release-buildstep "$APP" "$IMAGE_TAG"
|
||||
plugn trigger pre-release-buildpack "$APP" "$IMAGE_TAG"
|
||||
if [[ -n $(config_export global) ]]; then
|
||||
id=$(config_export global | docker run -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
|
||||
@@ -81,16 +81,17 @@ case "$1" in
|
||||
test "$(docker wait $id)" -eq 0
|
||||
docker commit $id $IMAGE > /dev/null
|
||||
fi
|
||||
# *DEPRECATED* in v0.3.15: `pluginhook post-release` will be removed in future releases
|
||||
pluginhook post-release $APP $IMAGE_TAG
|
||||
# *DEPRECATED* in v0.3.22: `pluginhook post-release-buildstep` will be removed in future releases
|
||||
pluginhook post-release-buildstep $APP $IMAGE_TAG
|
||||
pluginhook post-release-buildpack $APP $IMAGE_TAG
|
||||
# *DEPRECATED* in v0.3.15: `plugn trigger post-release` will be removed in future releases
|
||||
plugn trigger post-release "$APP" "$IMAGE_TAG"
|
||||
# *DEPRECATED* in v0.3.22: `plugn trigger post-release-buildstep` will be removed in future releases
|
||||
plugn trigger post-release-buildstep "$APP" "$IMAGE_TAG"
|
||||
plugn trigger post-release-buildpack "$APP" "$IMAGE_TAG"
|
||||
;;
|
||||
|
||||
dockerfile)
|
||||
pluginhook pre-release-dockerfile $APP $IMAGE_TAG
|
||||
pluginhook post-release-dockerfile $APP $IMAGE_TAG
|
||||
# buildstep plugins don't necessarily make sense for dockerfiles. call the new breed!!!
|
||||
plugn trigger pre-release-dockerfile "$APP" "$IMAGE_TAG"
|
||||
plugn trigger post-release-dockerfile "$APP" "$IMAGE_TAG"
|
||||
;;
|
||||
|
||||
*)
|
||||
@@ -175,8 +176,8 @@ case "$1" in
|
||||
|
||||
shift 2
|
||||
|
||||
DOCKER_ARGS=$(: | pluginhook docker-args $APP run $IMAGE_TAG)
|
||||
DOCKER_ARGS+=$(: | pluginhook docker-args-run $APP $IMAGE_TAG)
|
||||
DOCKER_ARGS=$(: | plugn trigger docker-args $APP run $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"
|
||||
@@ -222,7 +223,7 @@ case "$1" in
|
||||
;;
|
||||
|
||||
help)
|
||||
cat && cat<<EOF
|
||||
cat<<EOF
|
||||
ls, Pretty listing of deployed applications and containers
|
||||
logs <app> [-t], Show the last logs for an application (-t follows)
|
||||
run <app> <cmd>, Run a command in the environment of an application
|
||||
|
||||
4
plugins/00_dokku-standard/plugin.toml
Normal file
4
plugins/00_dokku-standard/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core standard plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
4
plugins/20_events/plugin.toml
Normal file
4
plugins/20_events/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core events logging plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -38,7 +38,7 @@ case "$1" in
|
||||
|
||||
echo "Destroying $APP (including all add-ons)"
|
||||
|
||||
pluginhook pre-delete $APP $IMAGE_TAG
|
||||
plugn trigger pre-delete $APP $IMAGE_TAG
|
||||
DOKKU_APP_CIDS=$(get_app_container_ids $APP)
|
||||
if [[ -n $DOKKU_APP_CIDS ]]; then
|
||||
for ID in $DOKKU_APP_CIDS;do
|
||||
@@ -47,11 +47,11 @@ case "$1" in
|
||||
done
|
||||
fi
|
||||
|
||||
pluginhook post-delete $APP $IMAGE_TAG
|
||||
plugn trigger post-delete $APP $IMAGE_TAG
|
||||
;;
|
||||
|
||||
help | apps:help)
|
||||
cat && cat<<EOF
|
||||
cat<<EOF
|
||||
apps, List your apps
|
||||
apps:create <app>, Create a new app
|
||||
apps:destroy <app>, Permanently destroy an app
|
||||
|
||||
4
plugins/apps/plugin.toml
Normal file
4
plugins/apps/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core apps plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -11,7 +11,7 @@ case "$1" in
|
||||
BACKUP_TMP_DIR=$(mktemp -d)
|
||||
BACKUP_TMP_FILE="$BACKUP_TMP_DIR/backup.tar"
|
||||
|
||||
: | pluginhook backup-export 1 $BACKUP_DIR | tar -cf $BACKUP_TMP_FILE --files-from -
|
||||
: | plugn trigger backup-export 1 $BACKUP_DIR | tar -cf $BACKUP_TMP_FILE --files-from -
|
||||
|
||||
pushd $BACKUP_DIR > /dev/null
|
||||
find . -maxdepth 1 -type d -not -name . | sed 's:./::g' > "$BACKUP_TMP_DIR/.dokku_backup_apps"
|
||||
@@ -63,7 +63,7 @@ case "$1" in
|
||||
BACKUP_ROOT="$BACKUP_TMP_DIR""$DOKKU_ROOT"
|
||||
TARGET_DIR="$DOKKU_ROOT"
|
||||
|
||||
if ! pluginhook backup-check $VERSION "$BACKUP_ROOT" "$TARGET_DIR" "$BACKUP_TMP_DIR/.dokku_backup_apps"; then
|
||||
if ! plugn trigger backup-check $VERSION "$BACKUP_ROOT" "$TARGET_DIR" "$BACKUP_TMP_DIR/.dokku_backup_apps"; then
|
||||
if $force; then
|
||||
echo "-f used. Ignoring warnings."
|
||||
else
|
||||
@@ -75,7 +75,7 @@ case "$1" in
|
||||
while read app; do mkdir "$TARGET_DIR/$app"; echo "Imported $app"; done < $BACKUP_TMP_DIR/.dokku_backup_apps
|
||||
|
||||
# have the plugins import their stuff
|
||||
pluginhook backup-import $VERSION "$BACKUP_ROOT" $TARGET_DIR "$BACKUP_TMP_DIR/.dokku_backup_apps"
|
||||
plugn trigger backup-import $VERSION "$BACKUP_ROOT" $TARGET_DIR "$BACKUP_TMP_DIR/.dokku_backup_apps"
|
||||
|
||||
rm -rf $BACKUP_TMP_DIR
|
||||
|
||||
@@ -83,7 +83,7 @@ case "$1" in
|
||||
;;
|
||||
|
||||
help | backup:help)
|
||||
cat && cat<<EOF
|
||||
cat<<EOF
|
||||
backup:export [file], Export dokku configuration files
|
||||
backup:import [file], Import dokku configuration files
|
||||
EOF
|
||||
|
||||
4
plugins/backup/plugin.toml
Normal file
4
plugins/backup/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core backup plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
4
plugins/build-env/plugin.toml
Normal file
4
plugins/build-env/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core build-env plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -144,7 +144,7 @@ case "$1" in
|
||||
if [[ -d "$APP_SSL_PATH" ]]; then
|
||||
dokku_log_info1 "Removing SSL endpoint from $APP"
|
||||
rm -rf $APP_SSL_PATH
|
||||
pluginhook post-domains-update $APP
|
||||
plugn trigger post-domains-update $APP
|
||||
else
|
||||
dokku_log_info1 "An app-specific SSL endpoint is not defined"
|
||||
fi
|
||||
|
||||
4
plugins/certs/plugin.toml
Normal file
4
plugins/certs/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core certificate management plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
4
plugins/checks/plugin.toml
Normal file
4
plugins/checks/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core checks plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
4
plugins/common/plugin.toml
Normal file
4
plugins/common/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core common plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -33,7 +33,7 @@ case "$1" in
|
||||
;;
|
||||
|
||||
help | config:help)
|
||||
cat && cat<<EOF
|
||||
cat<<EOF
|
||||
config (<app>|--global), Display all global or app-specific config vars
|
||||
config:get (<app>|--global) KEY, Display a global or app-specific config value
|
||||
config:set (<app>|--global) KEY1=VALUE1 [KEY2=VALUE2 ...], Set one or more config vars
|
||||
|
||||
4
plugins/config/plugin.toml
Normal file
4
plugins/config/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core config plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -140,7 +140,7 @@ case "$1" in
|
||||
|
||||
# Display usage help
|
||||
help)
|
||||
cat && cat<<EOF
|
||||
cat<<EOF
|
||||
docker-options <app>, Display apps docker options for all phases
|
||||
docker-options <app> <phase(s)>, Display apps docker options for phase (comma separated phase list)
|
||||
docker-options:add <app> <phase(s)> OPTION, Add docker option to app for phase (comma separated phase list)
|
||||
|
||||
4
plugins/docker-options/plugin.toml
Normal file
4
plugins/docker-options/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core docker-options plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -57,7 +57,7 @@ case "$1" in
|
||||
if [[ -f "$DOKKU_ROOT/VHOST" ]]; then
|
||||
dokku_log_info1 "Creating new $VHOST_PATH..."
|
||||
SUBDOMAIN=${APP/%\.${VHOST}/}
|
||||
hostname=$(: | pluginhook nginx-hostname $APP $SUBDOMAIN $VHOST)
|
||||
hostname=$(: | plugn trigger nginx-hostname $APP $SUBDOMAIN $VHOST)
|
||||
if [[ ! -n $hostname ]]; then
|
||||
if [[ "$APP" == *.* ]] && [[ "$SUBDOMAIN" == "$APP" ]]; then
|
||||
hostname="${APP/\//-}"
|
||||
@@ -95,7 +95,7 @@ case "$1" in
|
||||
done
|
||||
# we need to restart the app to make sure we're binding to the appropriate network interface
|
||||
dokku nginx:build-config $APP
|
||||
pluginhook post-domains-update $APP
|
||||
plugn trigger post-domains-update $APP
|
||||
for DOMAIN in "$@";do
|
||||
dokku_log_info1 "Added $DOMAIN to $APP"
|
||||
done
|
||||
@@ -109,7 +109,7 @@ case "$1" in
|
||||
|
||||
rm -f "$DOKKU_ROOT/$APP/VHOST"
|
||||
dokku domains:setup $APP
|
||||
pluginhook post-domains-update $APP
|
||||
plugn trigger post-domains-update $APP
|
||||
dokku_log_info1 "Cleared domains in $APP"
|
||||
|
||||
;;
|
||||
@@ -130,7 +130,7 @@ case "$1" in
|
||||
for DOMAIN in "$@";do
|
||||
sed -i "/^$DOMAIN$/d" "$DOKKU_ROOT/$APP/VHOST"
|
||||
done
|
||||
pluginhook post-domains-update $APP
|
||||
plugn trigger post-domains-update $APP
|
||||
for DOMAIN in "$@";do
|
||||
dokku_log_info1 "Removed $DOMAIN from $APP"
|
||||
done
|
||||
@@ -138,7 +138,7 @@ case "$1" in
|
||||
;;
|
||||
|
||||
help | domains:help)
|
||||
cat && cat<<EOF
|
||||
cat<<EOF
|
||||
domains <app>, List custom domains for app
|
||||
domains:add <app> DOMAIN, Add a custom domain to app
|
||||
domains:clear <app>, Clear all custom domains for app
|
||||
|
||||
4
plugins/domains/plugin.toml
Normal file
4
plugins/domains/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core domains plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
4
plugins/enter/plugin.toml
Normal file
4
plugins/enter/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core enter plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -36,11 +36,11 @@ case "$1" in
|
||||
# Only run this script for the master branch. You can remove this
|
||||
# if block if you wish to run it for others as well.
|
||||
if [[ $refname = "refs/heads/master" ]] ; then
|
||||
# broken out into pluginhook so we might support other methods to receive an app
|
||||
pluginhook -p receive-app $APP $newrev
|
||||
# broken out into plugin so we might support other methods to receive an app
|
||||
plugn trigger receive-app $APP $newrev
|
||||
else
|
||||
if test -f "$PLUGIN_PATH"/enabled/*/receive-branch; then
|
||||
pluginhook receive-branch $APP $newrev $refname
|
||||
plugn trigger receive-branch $APP $newrev $refname
|
||||
else
|
||||
echo $'\e[1G\e[K'"-----> WARNING: deploy did not complete, you must push to master."
|
||||
echo $'\e[1G\e[K'"-----> for example, try 'git push <dokku> ${refname/refs\/heads\/}:master'"
|
||||
@@ -51,9 +51,9 @@ case "$1" in
|
||||
|
||||
git-upload-pack)
|
||||
APP="$(echo $2 | perl -pe 's/(?<!\\)'\''//g' | sed 's/\\'\''/'\''/g')"
|
||||
pluginhook git-pre-pull $APP
|
||||
plugn trigger git-pre-pull $APP
|
||||
cat | git-upload-pack "$DOKKU_ROOT/$APP"
|
||||
pluginhook git-post-pull $APP
|
||||
plugn trigger git-post-pull $APP
|
||||
;;
|
||||
|
||||
git-build)
|
||||
@@ -100,7 +100,7 @@ EOF
|
||||
;;
|
||||
|
||||
help | git:help)
|
||||
cat
|
||||
echo -n ""
|
||||
;;
|
||||
|
||||
*)
|
||||
|
||||
4
plugins/git/plugin.toml
Normal file
4
plugins/git/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core git plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -130,7 +130,7 @@ EOF
|
||||
|
||||
if is_deployed "$APP"; then
|
||||
dokku_log_info1 "Running nginx-pre-reload"
|
||||
pluginhook nginx-pre-reload $APP $DOKKU_APP_LISTEN_PORT $DOKKU_APP_LISTEN_IP
|
||||
plugn trigger nginx-pre-reload $APP $DOKKU_APP_LISTEN_PORT $DOKKU_APP_LISTEN_IP
|
||||
|
||||
dokku_log_verbose "Reloading nginx"
|
||||
validate_nginx && restart_nginx
|
||||
@@ -160,7 +160,7 @@ EOF
|
||||
fi
|
||||
;;
|
||||
help | nginx:help)
|
||||
cat && cat<<EOF
|
||||
cat<<EOF
|
||||
nginx:build-config <app>, (Re)builds nginx config for given app
|
||||
EOF
|
||||
;;
|
||||
|
||||
4
plugins/nginx-vhosts/plugin.toml
Normal file
4
plugins/nginx-vhosts/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core nginx-vhosts plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -14,7 +14,7 @@ case "$1" in
|
||||
dokku_log_info1_quiet "running processes in container: $CID"
|
||||
docker exec $DOKKU_RUN_OPTS $CID /bin/sh -c "ps auxwww"
|
||||
done
|
||||
;;
|
||||
;;
|
||||
|
||||
ps:start)
|
||||
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
|
||||
@@ -28,7 +28,7 @@ case "$1" in
|
||||
else
|
||||
echo "App $APP already running"
|
||||
fi
|
||||
;;
|
||||
;;
|
||||
|
||||
ps:stop)
|
||||
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
|
||||
@@ -43,14 +43,14 @@ case "$1" in
|
||||
else
|
||||
echo "App $APP already stopped"
|
||||
fi
|
||||
;;
|
||||
;;
|
||||
|
||||
ps:rebuild)
|
||||
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
|
||||
APP="$2"; verify_app_name "$APP"
|
||||
|
||||
pluginhook -p receive-app $APP
|
||||
;;
|
||||
plugn trigger receive-app $APP
|
||||
;;
|
||||
|
||||
ps:rebuildall)
|
||||
shopt -s nullglob
|
||||
@@ -60,7 +60,7 @@ case "$1" in
|
||||
is_deployed $APP && dokku ps:rebuild $APP
|
||||
done
|
||||
shopt -u nullglob
|
||||
;;
|
||||
;;
|
||||
|
||||
ps:restart)
|
||||
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
|
||||
@@ -70,7 +70,7 @@ case "$1" in
|
||||
! (is_deployed $APP) && echo "App $APP has not been deployed" && exit 0
|
||||
|
||||
release_and_deploy "$APP" "$IMAGE_TAG"
|
||||
;;
|
||||
;;
|
||||
|
||||
ps:restartall)
|
||||
shopt -s nullglob
|
||||
@@ -80,7 +80,7 @@ case "$1" in
|
||||
dokku ps:restart $APP
|
||||
done
|
||||
shopt -u nullglob
|
||||
;;
|
||||
;;
|
||||
|
||||
ps:scale)
|
||||
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
|
||||
@@ -98,10 +98,10 @@ case "$1" in
|
||||
set_scale "$APP" "$@"
|
||||
release_and_deploy "$APP" "$IMAGE_TAG"
|
||||
fi
|
||||
;;
|
||||
;;
|
||||
|
||||
help | ps:help)
|
||||
cat && cat<<EOF
|
||||
cat<<EOF
|
||||
ps <app>, List processes running in app container(s)
|
||||
ps:scale <app> <proc>=<count> [<proc>=<count>], Set how many instances of a given process to run
|
||||
ps:start <app>, Start app container(s)
|
||||
|
||||
4
plugins/ps/plugin.toml
Normal file
4
plugins/ps/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core ps plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -47,7 +47,7 @@ case "$1" in
|
||||
;;
|
||||
|
||||
help | shell:help)
|
||||
cat && cat<<EOF
|
||||
cat<<EOF
|
||||
shell, Spawn dokku shell
|
||||
EOF
|
||||
;;
|
||||
|
||||
4
plugins/shell/plugin.toml
Normal file
4
plugins/shell/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core shell plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -20,7 +20,7 @@ case "$1" in
|
||||
|
||||
tag_image "$IMAGE_REPO:latest" "$IMAGE_REPO:$IMAGE_TAG"
|
||||
dokku_log_info2_quiet "Added $IMAGE_TAG tag to $IMAGE_REPO"
|
||||
pluginhook tags-create $APP $IMAGE_TAG
|
||||
plugn trigger tags-create $APP $IMAGE_TAG
|
||||
;;
|
||||
|
||||
tags:deploy)
|
||||
@@ -45,7 +45,7 @@ case "$1" in
|
||||
docker rmi "$IMAGE_REPO:$IMAGE_TAG"
|
||||
;;
|
||||
esac
|
||||
pluginhook tags-destroy $APP $IMAGE_TAG
|
||||
plugn trigger tags-destroy $APP $IMAGE_TAG
|
||||
;;
|
||||
|
||||
help | tags:help)
|
||||
|
||||
4
plugins/tags/plugin.toml
Normal file
4
plugins/tags/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core tags plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
@@ -15,7 +15,7 @@ case "$1" in
|
||||
APP="$2"
|
||||
verify_app_name "$2"
|
||||
tee "$DOKKU_ROOT/$APP/src.tar" | wc -c
|
||||
pluginhook -p receive-app $APP
|
||||
plugn trigger -p receive-app $APP
|
||||
;;
|
||||
|
||||
tar-build)
|
||||
|
||||
4
plugins/tar/plugin.toml
Normal file
4
plugins/tar/plugin.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[plugin]
|
||||
description = "dokku core tar plugin"
|
||||
version = "0.4.0"
|
||||
[plugin.config]
|
||||
Reference in New Issue
Block a user