implement dokku shell and ls (by @plietar). refs #312

This commit is contained in:
Michael Hobbs committed 2015-02-07 14:46:17 -08:00
1 parent b10120af12
commit 1cfb1fc3fc
5 files changed
+112 -1

No files matched your search

+15
View File
@@ -25,6 +25,20 @@ case "$1" in
dokku apps:destroy $2
;;
ls)
apps=$(ls -d $DOKKU_ROOT/*/ 2>/dev/null) || (echo "You haven't depoyed any applications yet" && exit 1)
dokku_col_log_info2_quiet "App Name" "Container id"
for app in $apps; do
if [[ -f $app/CONTAINER ]]; then
dokku_col_log_msg "$(basename $app)" "$(< $app/CONTAINER)"
else
dokku_col_log_msg "$(basename $app)"
fi
done
;;
logs)
[[ -z $2 ]] && echo "Please specify an app to run the command on" && exit 1
verify_app_name "$2"
@@ -93,6 +107,7 @@ case "$1" in
help)
cat && 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
url <app> Show the first URL for an application (compatibility)