feat: sanitize docker inspect output with ps:inspect
Often-times, we will want to have the container inspect output for debugging purposes, but this process is: - error prone, as the user needs to know what their containers are - potentially insecure, as the output must be sanitized of sensitive data Instead of making users wade through this process, we provide a helper `ps:inspect` command, that can be used to diagnose problems associated with containers that may or may not exist for an application.
This commit is contained in:
@@ -12,6 +12,17 @@ teardown() {
|
||||
global_teardown
|
||||
}
|
||||
|
||||
@test "(ps) ps:inspect" {
|
||||
deploy_app dockerfile
|
||||
|
||||
CID=$(< $DOKKU_ROOT/$TEST_APP/CONTAINER.web.1)
|
||||
run bash -c "dokku ps:inspect $TEST_APP"
|
||||
echo "output: "$output
|
||||
echo "status: "$status
|
||||
assert_success
|
||||
assert_output_contains "$CID" 6
|
||||
}
|
||||
|
||||
@test "(ps:scale) procfile commands extraction" {
|
||||
source "$PLUGIN_CORE_AVAILABLE_PATH/ps/functions"
|
||||
cat <<EOF > "$DOKKU_ROOT/$TEST_APP/DOKKU_PROCFILE"
|
||||
|
||||
Reference in New Issue
Block a user