From c773e5250860c3a6e77b6acc8101d4a204c5b937 Mon Sep 17 00:00:00 2001 From: Alexander Date: Sun, 18 Aug 2013 14:19:41 +0200 Subject: [PATCH] Add dokku run-cli command to run commands in the app env --- plugins/00_dokku-standard/commands | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/plugins/00_dokku-standard/commands b/plugins/00_dokku-standard/commands index afe27d8a6..7a392aa6d 100755 --- a/plugins/00_dokku-standard/commands +++ b/plugins/00_dokku-standard/commands @@ -5,6 +5,20 @@ set -e; case "$1" in docker logs $CONTAINER | tail -n 100 ;; + run-cli) + if [[ -z $2 ]]; then + echo "Please specify an app to run the command on" + exit 1 + fi + APP="$2"; IMAGE="app/$APP" + if [[ ! -d "/home/git/$APP" ]]; then + echo "App $APP does not exist" + exit 1 + fi + shift 2 + docker run $IMAGE /run-cli "$@" + ;; + help) cat && cat< Show the last logs for an application