Skip to content

client: ImageBuildResponse: remove OSType field#50995

Merged
thaJeztah merged 1 commit intomoby:masterfrom
thaJeztah:rm_build_ostype
Sep 17, 2025
Merged

client: ImageBuildResponse: remove OSType field#50995
thaJeztah merged 1 commit intomoby:masterfrom
thaJeztah:rm_build_ostype

Conversation

@thaJeztah
Copy link
Member

relates to:

This field was used in the CLI to produce a warning added in moby@4a8b3ca to print a warning when building Linux images from a Windows client. Window's filesystem does not have an "executable" bit, which mean that, for example, copying a shell script to an image during build would lose the executable bit. So for Windows clients, the executable bit would be set on all files, unconditionally.

Originally this was detected in the client, which had direct access to the API response headers, but when refactoring the client to use a common library in moby@535c4c9, this was refactored into a ImageBuildResponse wrapper, deconstructing the API response into an io.Reader and a string field containing only the OSType header.

The warning was removed in cli@af65ee4, so we don't have to carry this field in the new client module going forward.

With the field removed, we can consider the client to return the full HTTP response again, but leaving that for a follow-up, as we may want to rewrite these streaming functions altogether.

- What I did

- How I did it

- How to verify it

- Human readable description for the release notes

client: ImageBuildResponse: remove OSType field.

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

This field was used in the CLI to produce a warning added in [moby/moby@4a8b3ca]
to print a warning when building Linux images from a Windows client.
Window's filesystem does not have an "executable" bit, which mean that,
for example, copying a shell script to an image during build would lose
the executable bit. So for Windows clients, the executable bit would be
set on all files, unconditionally.

Originally this was detected in the client, which had direct access to
the API response headers, but when refactoring the client to use a common
library in [moby/moby@535c4c9], this was refactored into a `ImageBuildResponse`
wrapper, deconstructing the API response into an `io.Reader` and a string
field containing only the `OSType` header.

The warning was removed in [cli@af65ee4], so we don't have to carry this
field in the new client module going forward.

With the field removed, we can consider the client to return the full
HTTP response again, but leaving that for a follow-up, as we may want
to rewrite these streaming functions altogether.

[moby/moby@4a8b3ca]: moby@4a8b3ca
[moby/moby@535c4c9]: moby@535c4c9
[cli@af65ee4]: docker/cli@af65ee4

Signed-off-by: Sebastiaan van Stijn <[email protected]>
@thaJeztah thaJeztah merged commit 5a58272 into moby:master Sep 17, 2025
240 of 243 checks passed
@thaJeztah thaJeztah deleted the rm_build_ostype branch September 17, 2025 13:15
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