From a06a58f79a89aff5c0c2db00ab962a13748dfa56 Mon Sep 17 00:00:00 2001 From: Michael Schlapa Date: Wed, 6 Oct 2021 12:38:35 +0200 Subject: [PATCH] Add JSON output for docker --- containerization/docker.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/containerization/docker.md b/containerization/docker.md index c8e176a..c791ba3 100644 --- a/containerization/docker.md +++ b/containerization/docker.md @@ -1 +1,11 @@ # docker + +## Output format + +You can change the output format of any (?) docker command to JSON by using the following parameter: + +``` +docker ps -a --format '{{json .}}' +``` + +It uses the Go templating engine.