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

Support parallel local builds (defaults to sequential) #3471

Merged
merged 1 commit into from
Jan 8, 2020

Conversation

dgageot
Copy link
Contributor

@dgageot dgageot commented Jan 2, 2020

Had to cherry pick the schema change from #3453

Fixes #1380

@codecov
Copy link

codecov bot commented Jan 2, 2020

Codecov Report

Merging #3471 into master will increase coverage by 0.04%.
The diff coverage is 100%.

Impacted Files Coverage Δ
pkg/skaffold/schema/latest/config.go 100% <ø> (ø) ⬆️
pkg/skaffold/build/local/local.go 54.54% <100%> (ø) ⬆️
pkg/skaffold/schema/defaults/defaults.go 94.31% <100%> (+0.34%) ⬆️
pkg/skaffold/build/local/types.go 68.57% <100%> (ø) ⬆️
...affold/kubernetes/portforward/kubectl_forwarder.go 68.29% <0%> (+2.43%) ⬆️

@dgageot dgageot force-pushed the local-parallel branch 2 times, most recently from b803822 to 08d07cf Compare January 3, 2020 15:09
@dgageot dgageot added size/M and removed size/XXL labels Jan 6, 2020
Copy link
Member

@briandealwis briandealwis left a comment

Choose a reason for hiding this comment

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

So my concern here is that concurrent builds are enabled for all local builders. But Jib-based multi-module projects (artifacts that share the same context / workspace) will encounter problems.

pkg/skaffold/schema/defaults/defaults.go Outdated Show resolved Hide resolved
@loosebazooka
Copy link
Member

Is it possible to selectively disable parallel builds?

@dgageot
Copy link
Contributor Author

dgageot commented Jan 7, 2020

@loosebazooka selectively how? With this PR, local parallel builds are disabled by default. Users can activate them by changing the skaffold.yaml.

@loosebazooka
Copy link
Member

I see, can each builder decide if it wants to participate in parallel builds?

@dgageot
Copy link
Contributor Author

dgageot commented Jan 7, 2020

@loosebazooka not for now

Copy link
Contributor

@nkubala nkubala left a comment

Choose a reason for hiding this comment

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

@dgageot dgageot added the docs-modifications runs the docs preview service on the given PR label Jan 8, 2020
@container-tools-bot
Copy link

Please visit http://35.236.51.86:1313 to view changes to the docs.

@container-tools-bot container-tools-bot removed the docs-modifications runs the docs preview service on the given PR label Jan 8, 2020
@dgageot
Copy link
Contributor Author

dgageot commented Jan 8, 2020

@nkubala This is documented on that page. See http://35.236.51.86:1313/docs/pipeline-stages/builders/

Defaults to a sequential build

Fixes GoogleContainerTools#1380

Signed-off-by: David Gageot <david@gageot.net>
@nkubala
Copy link
Contributor

nkubala commented Jan 8, 2020

@dgageot well, the concurrency flag is documented, but there isn't really anything saying "we support building locally in parallel, but it's disabled by default". it would be nice to say something like that so people know the feature exists

Copy link
Contributor

@nkubala nkubala left a comment

Choose a reason for hiding this comment

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

i'll approve this, but i'd like to see the docs on building improved to discuss sequence vs. parallel and how this can be configured by users. right now it's probably hard for users to discover this

@dgageot
Copy link
Contributor Author

dgageot commented Jan 8, 2020

Let’s do that. Can you merge this one and I’ll edit the doc tomorrow for both local and remote builders?

@nkubala nkubala merged commit 45c887d into GoogleContainerTools:master Jan 8, 2020
@nkubala
Copy link
Contributor

nkubala commented Jan 8, 2020

👍

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.

Add parallel local image building.
6 participants