Skip to content

API: improve swagger and go-doc for ImageInspect structs#43300

Merged
thaJeztah merged 6 commits intomoby:masterfrom
thaJeztah:api_update_imageinspect_docs
Mar 5, 2022
Merged

API: improve swagger and go-doc for ImageInspect structs#43300
thaJeztah merged 6 commits intomoby:masterfrom
thaJeztah:api_update_imageinspect_docs

Conversation

@thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Feb 28, 2022

  • addresses ContainerConfig field missing with buildkit docker/cli#2868
  • rename definition in swagger from Image to ImageInspect to match the go type
  • improve (or add) documentation for various fields
  • move example values in-line in the "definitions" section
  • remove the required fields from ImageInspect, as the type is only used as
    response type (not to make requests).

also improve go-doc for some structs accordingly, and update API docs for v1.39-v1.41 with the same changes

@thaJeztah thaJeztah marked this pull request as draft February 28, 2022 20:59
@thaJeztah thaJeztah force-pushed the api_update_imageinspect_docs branch from b76069e to 71cdde7 Compare February 28, 2022 21:07
@thaJeztah thaJeztah marked this pull request as ready for review February 28, 2022 21:07
@thaJeztah thaJeztah force-pushed the api_update_imageinspect_docs branch 2 times, most recently from 8895364 to c7025c3 Compare March 1, 2022 00:03
Copy link
Member

@tianon tianon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall I like it, just a few nits on the specific terminology added to the godocs, which I realized later might not actually be new verbiage (rather copied from elsewhere)?

- rename definition in swagger from `Image` to `ImageInspect` to match the go type
- improve (or add) documentation for various fields
- move example values in-line in the "definitions" section
- remove the `required` fields from `ImageInspect`, as the type is only used as
  response type (not to make requests).

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
    5428:7    warning  comment not indented like content  (comments-indentation)

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
- rename definition in swagger from `Image` to `ImageInspect` to match the go type
- improve (or add) documentation for various fields
- move example values in-line in the "definitions" section
- remove the `required` fields from `ImageInspect`, as the type is only used as
  response type (not to make requests).

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
    5428:7 warning comment not indented like content (comments-indentation)

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
@thaJeztah thaJeztah force-pushed the api_update_imageinspect_docs branch from c7025c3 to 565b1f5 Compare March 3, 2022 21:55
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
@thaJeztah thaJeztah force-pushed the api_update_imageinspect_docs branch from 565b1f5 to 06df530 Compare March 3, 2022 21:57
@thaJeztah
Copy link
Member Author

@tianon updated, PTAL ❤️

Copy link
Member

@tianon tianon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 ❤️

@thaJeztah thaJeztah added this to the 21.xx milestone Mar 5, 2022
@thaJeztah
Copy link
Member Author

Bringing this one in; I have a couple more follow-up changes in the swagger file(s)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants