feat: add support for enhanced help output
This commit is contained in:
12
functions
12
functions
@@ -2,6 +2,7 @@
|
||||
source "$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)/config"
|
||||
set -eo pipefail; [[ $DOKKU_TRACE ]] && set -x
|
||||
source "$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)/common-functions"
|
||||
source "$PLUGIN_BASE_PATH/common/functions"
|
||||
source "$PLUGIN_AVAILABLE_PATH/config/functions"
|
||||
if [[ -f "$PLUGIN_AVAILABLE_PATH/docker-options/functions" ]]; then
|
||||
source "$PLUGIN_AVAILABLE_PATH/docker-options/functions"
|
||||
@@ -9,6 +10,17 @@ fi
|
||||
|
||||
# non-generic functions
|
||||
|
||||
service_connect() {
|
||||
local SERVICE="$1"
|
||||
local SERVICE_ROOT="$PLUGIN_DATA_ROOT/$SERVICE"
|
||||
local SERVICE_NAME="$(get_service_name "$SERVICE")"
|
||||
local PASSWORD="$(service_password "$SERVICE")"
|
||||
local SERVICE_TTY_OPTS
|
||||
has_tty && SERVICE_TTY_OPTS="-t"
|
||||
|
||||
docker exec -i $SERVICE_TTY_OPTS "$SERVICE_NAME" redis-cli -a "$PASSWORD"
|
||||
}
|
||||
|
||||
service_create() {
|
||||
local SERVICE="$1"
|
||||
[[ -z "$SERVICE" ]] && dokku_log_fail "Please specify a name for the service"
|
||||
|
||||
Reference in New Issue
Block a user