Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

collect built image IDs #10372

Merged
merged 1 commit into from Mar 15, 2023
Merged

collect built image IDs #10372

merged 1 commit into from Mar 15, 2023

Conversation

ndeloof
Copy link
Contributor

@ndeloof ndeloof commented Mar 14, 2023

What I did
Fix collection of built image IDs.

We used a map[string]string to be overridden by subsequent calls to s.doBuild, so loosing earlier results (wonder this didn't resulted in some bugs...).

Replaced by a pre-allocated []string using service index from project.Services to record IDs collected by goroutines at a known position.

Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
@ndeloof
Copy link
Contributor Author

ndeloof commented Mar 14, 2023

I assume this used to work because buildx does not only return the built IDs for last call, but all the built IDs for the active session.

Copy link
Contributor

@milas milas left a comment

Choose a reason for hiding this comment

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

Nice fix!

@ndeloof ndeloof merged commit e492330 into docker:v2 Mar 15, 2023
@ndeloof ndeloof deleted the builder branch March 15, 2023 08:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants