Skip to content

hack: Load special images on demand #46894

Merged
thaJeztah merged 1 commit intomoby:masterfrom
vvoland:hack-load-specialimages
Dec 7, 2023
Merged

hack: Load special images on demand #46894
thaJeztah merged 1 commit intomoby:masterfrom
vvoland:hack-load-specialimages

Conversation

@vvoland
Copy link
Copy Markdown
Contributor

@vvoland vvoland commented Dec 5, 2023

Rewrite .build-empty-images shell script that produced special images (emptyfs with no layers, and empty danglign image) to a Go functions that construct the same archives in a temporary directory.

Use them to load these images on demand only in the tests that need them.

- How to verify it
CI

- Description for the changelog

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

@vvoland vvoland added this to the 25.0.0 milestone Dec 5, 2023
@vvoland vvoland requested a review from tianon as a code owner December 5, 2023 11:12
@vvoland vvoland force-pushed the hack-load-specialimages branch from 3efe335 to 83eb0d3 Compare December 5, 2023 11:43
@vvoland vvoland self-assigned this Dec 5, 2023
@vvoland
Copy link
Copy Markdown
Contributor Author

vvoland commented Dec 5, 2023

Ugh, Windows seems to have issues with empty layers 😅

=== FAIL: github.com/docker/docker/integration-cli TestDockerCLISaveLoadSuite/TestSaveMultipleNames (0.57s)
    docker_utils_test.go:493: assertion failed: 
        Command:  D:\a\moby\moby\out\docker.exe load -i C:\Users\RUNNER~1\AppData\Local\Temp\TestDockerCLISaveLoadSuiteTestSaveMultipleNames687459830\001\image.tar
        ExitCode: 1
        Error:    exit status 1
        Stdout:   
        Stderr:   re-exec error: exit status 1: output: hcsshim::ProcessBaseLayer \\?\C:\Users\runneradmin\AppData\Local\Temp\moby-root\windowsfilter\5b50fed530d212f8aa18ae80db80176c8f7b3165a17055652239c140dbee36a8: The system cannot find the path specified.

@vvoland vvoland force-pushed the hack-load-specialimages branch from 83eb0d3 to 9c1b63d Compare December 5, 2023 12:33
Rewrite `.build-empty-images` shell script that produced special images
(emptyfs with no layers, and empty danglign image) to a Go functions
that construct the same archives in a temporary directory.

Use them to load these images on demand only in the tests that need
them.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
@vvoland vvoland force-pushed the hack-load-specialimages branch from 9c1b63d to bc94dfc Compare December 6, 2023 16:16
Copy link
Copy Markdown
Member

@thaJeztah thaJeztah left a comment

Choose a reason for hiding this comment

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

LGTM

@thaJeztah
Copy link
Copy Markdown
Member

@dmcgowan @neersighted ptal

@thaJeztah thaJeztah merged commit 82a318d into moby:master Dec 7, 2023
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.

3 participants