Skip to content

[23.0 backport] fix docker info, docker version --format=json not outputting json format - #4230

Merged
thaJeztah merged 4 commits into
docker:23.0from
thaJeztah:23.0_backport_docker_info_json
Apr 26, 2023
Merged

[23.0 backport] fix docker info, docker version --format=json not outputting json format#4230
thaJeztah merged 4 commits into
docker:23.0from
thaJeztah:23.0_backport_docker_info_json

Conversation

@thaJeztah

Copy link
Copy Markdown
Member

fix docker info --format=json not outputting json format

The --format=json option was added for all inspect commands, but was not implemented for "docker info". This patch implements the missing option.

Before this patch:

docker info --format=json
json

With this patch applied:

docker info --format=json
{"ID":"80c2f18a-2c88-4e4a-ba69-dca0eea59835","Containers":7,"ContainersRunning":"..."}

fix docker version --format=json not outputting json format

The --format=json option was added for all inspect commands, but was not
implemented for "docker version". This patch implements the missing option.

Before this patch:

docker version --format=json
json

With this patch:

docker version --format=json
{"Client":{"Platform":{"Name":""},"Version":"24.0.0-dev","ApiVersion":"..."}}

- Description for the changelog

- A picture of a cute animal (not mandatory but encouraged)

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 1aaa179)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
The --format=json option was added for all inspect commands, but was not implemented
for "docker info". This patch implements the missing option.
Before this patch:
docker info --format=json
json
With this patch applied:
docker info --format=json
{"ID":"80c2f18a-2c88-4e4a-ba69-dca0eea59835","Containers":7,"ContainersRunning":"..."}
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 46234b8)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 80640bc)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
The --format=json option was added for all inspect commands, but was not
implemented for "docker version". This patch implements the missing option.
Before this patch:
docker version --format=json
json
With this patch:
docker version --format=json
{"Client":{"Platform":{"Name":""},"Version":"24.0.0-dev","ApiVersion":"..."}}
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 23bd746)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

Merging #4230 (f914316) into 23.0 (ced769f) will increase coverage by 0.01%.
The diff coverage is 90.90%.

Additional details and impacted files
@@ Coverage Diff @@## 23.0 #4230 +/- ##
==========================================
+ Coverage 58.83% 58.84% +0.01% 
==========================================
Files 572 572 Lines 49610 49608 -2 ==========================================
+ Hits 29188 29192 +4 + Misses 18648 18642 -6 
Partials 1774 1774 

@thaJeztah
thaJeztah merged commit 8e00eb4 into docker:23.0Apr 26, 2023
@thaJeztah
thaJeztah deleted the 23.0_backport_docker_info_json branch April 26, 2023 11:00
@dockerdocker deleted a comment Oct 17, 2023
@dockerdocker deleted a comment Oct 17, 2023
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@thaJeztah@codecov-commenter@sam-thibault