Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save ksmandersen/4e521ae4d4b2297b7532bf2c82119a6c to your computer and use it in GitHub Desktop.
Save ksmandersen/4e521ae4d4b2297b7532bf2c82119a6c to your computer and use it in GitHub Desktop.
+ export DOKKU_DISTRO
++ . /etc/os-release
++ echo ubuntu
+ DOKKU_DISTRO=ubuntu
+ export DOKKU_IMAGE=gliderlabs/herokuish
+ DOKKU_IMAGE=gliderlabs/herokuish
+ export DOKKU_LIB_ROOT=/var/lib/dokku
+ DOKKU_LIB_ROOT=/var/lib/dokku
+ export PLUGIN_PATH=/var/lib/dokku/plugins
+ PLUGIN_PATH=/var/lib/dokku/plugins
+ export PLUGIN_AVAILABLE_PATH=/var/lib/dokku/plugins/available
+ PLUGIN_AVAILABLE_PATH=/var/lib/dokku/plugins/available
+ export PLUGIN_ENABLED_PATH=/var/lib/dokku/plugins/enabled
+ PLUGIN_ENABLED_PATH=/var/lib/dokku/plugins/enabled
+ export PLUGIN_CORE_PATH=/var/lib/dokku/core-plugins
+ PLUGIN_CORE_PATH=/var/lib/dokku/core-plugins
+ export PLUGIN_CORE_AVAILABLE_PATH=/var/lib/dokku/core-plugins/available
+ PLUGIN_CORE_AVAILABLE_PATH=/var/lib/dokku/core-plugins/available
+ export PLUGIN_CORE_ENABLED_PATH=/var/lib/dokku/core-plugins/enabled
+ PLUGIN_CORE_ENABLED_PATH=/var/lib/dokku/core-plugins/enabled
+ export DOKKU_API_VERSION=1
+ DOKKU_API_VERSION=1
+ export DOKKU_NOT_IMPLEMENTED_EXIT=10
+ DOKKU_NOT_IMPLEMENTED_EXIT=10
+ export DOKKU_VALID_EXIT=0
+ DOKKU_VALID_EXIT=0
+ export DOKKU_LOGS_DIR=/var/log/dokku
+ DOKKU_LOGS_DIR=/var/log/dokku
+ export DOKKU_EVENTS_LOGFILE=/var/log/dokku/events.log
+ DOKKU_EVENTS_LOGFILE=/var/log/dokku/events.log
+ export DOKKU_CONTAINER_LABEL=dokku
+ DOKKU_CONTAINER_LABEL=dokku
+ export DOKKU_GLOBAL_RUN_ARGS=--label=dokku
+ DOKKU_GLOBAL_RUN_ARGS=--label=dokku
+ source /var/lib/dokku/core-plugins/available/common/functions
++ set -eo pipefail
++ [[ -n 1 ]]
++ set -x
+ parse_args redis:enter speakerdex-sessions
+ declare 'desc=top-level cli arg parser'
+ local next_index=1
+ local skip=false
+ args=("$@")
+ local args
+ for arg in '"$@"'
+ [[ false == \t\r\u\e ]]
+ case "$arg" in
+ next_index=2
+ for arg in '"$@"'
+ [[ false == \t\r\u\e ]]
+ case "$arg" in
+ next_index=3
+ return 0
+ args=("$@")
+ skip_arg=false
+ [[ redis:enter =~ ^--.* ]]
+ has_tty
+ declare 'desc=return 0 if we have a tty'
++ /usr/bin/tty
+ [[ /dev/pts/0 == \n\o\t\ \a\ \t\t\y ]]
+ return 0
++ id -un
+ [[ dokku != \d\o\k\k\u ]]
+ [[ redis:enter =~ ^plugin:.* ]]
+ [[ redis:enter == \s\s\h\-\k\e\y\s\:\a\d\d ]]
+ [[ -n '' ]]
+ dokku_auth redis:enter speakerdex-sessions
+ declare 'desc=calls user-auth plugin trigger'
+ export SSH_USER=root
+ SSH_USER=root
+ export SSH_NAME=default
+ SSH_NAME=default
+ plugn trigger user-auth root default redis:enter speakerdex-sessions
+ source /var/lib/dokku/core-plugins/available/common/functions
++ set -eo pipefail
++ [[ -n 1 ]]
++ set -x
+ [[ ! -n '' ]]
+ source /var/lib/dokku/core-plugins/available/common/functions
++ set -eo pipefail
++ [[ -n 1 ]]
++ set -x
+ [[ redis:enter =~ (ssh-keys:add|ssh-keys:remove) ]]
+ return 0
+ case "$1" in
+ execute_dokku_cmd redis:enter speakerdex-sessions
+ declare 'desc=executes dokku sub-commands'
+ local PLUGIN_NAME=redis:enter
+ local PLUGIN_CMD=redis:enter
+ local implemented=0
+ local script
+ argv=("$@")
+ local argv
+ case "$PLUGIN_NAME" in
++ readlink -f /var/lib/dokku/plugins/enabled/redis
+ [[ /var/lib/dokku/plugins/available/redis == *core-plugins* ]]
+ [[ -x /var/lib/dokku/plugins/enabled/redis:enter/subcommands/default ]]
+ [[ -x /var/lib/dokku/plugins/enabled/redis:enter/subcommands/redis:enter ]]
+ [[ -x /var/lib/dokku/plugins/enabled/redis/subcommands/enter ]]
+ /var/lib/dokku/plugins/enabled/redis/subcommands/enter redis:enter speakerdex-sessions
+ source /var/lib/dokku/plugins/enabled/common/functions
++ set -eo pipefail
++ [[ -n 1 ]]
++ set -x
++++ dirname /var/lib/dokku/plugins/enabled/redis/subcommands/enter
+++ cd /var/lib/dokku/plugins/enabled/redis/subcommands
+++ pwd
++ dirname /var/lib/dokku/plugins/enabled/redis/subcommands
+ source /var/lib/dokku/plugins/enabled/redis/functions
++++ dirname /var/lib/dokku/plugins/enabled/redis/functions
+++ cd /var/lib/dokku/plugins/enabled/redis
+++ pwd
++ source /var/lib/dokku/plugins/enabled/redis/config
+++ export REDIS_IMAGE=redis
+++ REDIS_IMAGE=redis
+++ export REDIS_IMAGE_VERSION=3.2.8
+++ REDIS_IMAGE_VERSION=3.2.8
+++ export REDIS_ROOT=/var/lib/dokku/services/redis
+++ REDIS_ROOT=/var/lib/dokku/services/redis
+++ export PLUGIN_COMMAND_PREFIX=redis
+++ PLUGIN_COMMAND_PREFIX=redis
+++ export PLUGIN_DATA_ROOT=/var/lib/dokku/services/redis
+++ PLUGIN_DATA_ROOT=/var/lib/dokku/services/redis
+++ PLUGIN_DATASTORE_PORTS=(6379)
+++ export PLUGIN_DATASTORE_PORTS
+++ export PLUGIN_DATASTORE_WAIT_PORT=6379
+++ PLUGIN_DATASTORE_WAIT_PORT=6379
+++ export PLUGIN_DEFAULT_ALIAS=REDIS
+++ PLUGIN_DEFAULT_ALIAS=REDIS
+++ export PLUGIN_ALT_ALIAS=DOKKU_REDIS
+++ PLUGIN_ALT_ALIAS=DOKKU_REDIS
+++ export PLUGIN_IMAGE=redis
+++ PLUGIN_IMAGE=redis
+++ export PLUGIN_IMAGE_VERSION=3.2.8
+++ PLUGIN_IMAGE_VERSION=3.2.8
+++ export PLUGIN_SCHEME=redis
+++ PLUGIN_SCHEME=redis
+++ export PLUGIN_SERVICE=Redis
+++ PLUGIN_SERVICE=Redis
+++ export PLUGIN_VARIABLE=REDIS
+++ PLUGIN_VARIABLE=REDIS
+++ export PLUGIN_BASE_PATH=/var/lib/dokku/plugins
+++ PLUGIN_BASE_PATH=/var/lib/dokku/plugins
+++ [[ -n 1 ]]
+++ export PLUGIN_BASE_PATH=/var/lib/dokku/plugins/enabled
+++ PLUGIN_BASE_PATH=/var/lib/dokku/plugins/enabled
+++ [[ -d /var/lib/dokku/services/redis/* ]]
++ set -eo pipefail
++ [[ -n 1 ]]
++ set -x
++++ dirname /var/lib/dokku/plugins/enabled/redis/functions
+++ cd /var/lib/dokku/plugins/enabled/redis
+++ pwd
++ source /var/lib/dokku/plugins/enabled/redis/common-functions
+++ set -eo pipefail
+++ [[ -n 1 ]]
+++ set -x
++ source /var/lib/dokku/plugins/available/config/functions
+++ set -eo pipefail
+++ [[ -n 1 ]]
+++ set -x
+++ source /var/lib/dokku/core-plugins/available/common/functions
++++ set -eo pipefail
++++ [[ -n 1 ]]
++++ set -x
++ [[ -f /var/lib/dokku/plugins/available/docker-options/functions ]]
++ source /var/lib/dokku/plugins/available/docker-options/functions
+++ set -eo pipefail
+++ [[ -n 1 ]]
+++ set -x
+++ source /var/lib/dokku/core-plugins/available/common/functions
++++ set -eo pipefail
++++ [[ -n 1 ]]
++++ set -x
+++ AVAILABLE_PHASES=(build deploy run)
+ redis-enter-cmd redis:enter speakerdex-sessions
+ declare 'desc=enter or run a command in a running Redis service container'
+ argv=("$@")
+ local cmd=redis:enter argv
+ [[ redis:enter == \r\e\d\i\s\:\e\n\t\e\r ]]
+ shift 1
+ declare SERVICE=speakerdex-sessions
+ shift 1
+ dokku_log_info1_quiet 'Filesystem changes may not persist after container restarts'
+ declare 'desc=log info1 formatter (with quiet option)'
+ [[ -z '' ]]
+ echo '-----> Filesystem changes may not persist after container restarts'
-----> Filesystem changes may not persist after container restarts
+ service_enter speakerdex-sessions
+ declare 'desc=enters running app container of specified proc type'
+ declare SERVICE=speakerdex-sessions
+ shift 1
+ local SERVICE_ROOT=/var/lib/dokku/services/redis/speakerdex-sessions
++ cat /var/lib/dokku/services/redis/speakerdex-sessions/ID
+ local ID=bf439119bf83cb1c9dda6b029b128f4bfd57bcc175ba9e4eb1a4696ea6afa911
+ docker inspect bf439119bf83cb1c9dda6b029b128f4bfd57bcc175ba9e4eb1a4696ea6afa911
+ is_container_status bf439119bf83cb1c9dda6b029b128f4bfd57bcc175ba9e4eb1a4696ea6afa911 Running
+ declare 'desc=return 0 if given docker container id is in given state'
+ local CID=bf439119bf83cb1c9dda6b029b128f4bfd57bcc175ba9e4eb1a4696ea6afa911
+ local 'TEMPLATE={{.State.Running}}'
++ docker inspect -f '{{.State.Running}}' bf439119bf83cb1c9dda6b029b128f4bfd57bcc175ba9e4eb1a4696ea6afa911
+ local CONTAINER_STATUS=true
+ [[ true == \t\r\u\e ]]
+ return 0
+ local EXEC_CMD=
+ has_tty
+ declare 'desc=return 0 if we have a tty'
++ /usr/bin/tty
+ [[ /dev/pts/0 == \n\o\t\ \a\ \t\t\y ]]
+ return 0
+ local 'DOKKU_RUN_OPTS+= -i -t'
+ docker exec -i -t bf439119bf83cb1c9dda6b029b128f4bfd57bcc175ba9e4eb1a4696ea6afa911 /bin/bash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment