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

Decouple building binaries from images #1078

Merged
merged 1 commit into from
Feb 4, 2020
Merged

Decouple building binaries from images #1078

merged 1 commit into from
Feb 4, 2020

Conversation

johnSchnake
Copy link
Contributor

@johnSchnake johnSchnake commented Jan 31, 2020

As a precursor to supporting Windows builds, I'm separating out
more parts of our build in CircleCI.

Major changes:

  • unit tests in parallel with other build steps
  • separate building the binaries, building the images, and running
    integration tests
  • using workspaces to persist binaries/images across jobs

Total time to run the workflow decreased by about 3m (30%) since
the unit tests were no longer on the critical path.

@johnSchnake johnSchnake changed the title WIP: Trying to decouple building binaries from images Decouple building binaries from images Jan 31, 2020
@johnSchnake johnSchnake requested a review from zubron January 31, 2020 19:04
@johnSchnake johnSchnake marked this pull request as ready for review January 31, 2020 19:05
@johnSchnake
Copy link
Contributor Author

Comparison of master vs new build flow:

12:51 time to run on master: https://app.circleci.com/github/johnSchnake/sonobuoy/pipelines/524f2171-3763-4b92-a60c-f833bd0c2816/workflows/406651f0-26cf-4703-abe5-552bd64fb4e3

9:10 time to run on this branch: https://app.circleci.com/github/johnSchnake/sonobuoy/pipelines/29d5474c-dc00-4eff-8600-5a4b1ce5713e/workflows/b4acdb26-5344-4505-b71c-ef47fb1c6cc4

Confirmed artifacts still created for the integration tests as expected (wanted to make sure it wasn't really doing a noop or erroring out silently).

@johnSchnake
Copy link
Contributor Author

ci/circleci: build_and_test is saying waiting but everything is green and build_and_test isn't even in the config anymore. I think this is just a holdover as this is on master but not on this branch?

Copy link
Contributor

@zubron zubron left a comment

Choose a reason for hiding this comment

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

Just a few things that need to be updated in the Makefile but this looks good!

@@ -119,7 +119,7 @@ build_container:
-f $(DOCKERFILE) \
.

container: sonobuoy
containers: build/linux/arm64/sonobuoy build/linux/amd64/sonobuoy
Copy link
Contributor

Choose a reason for hiding this comment

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

I can't leave a comment on all the lines that need to be updated, but the following targets need to have their dependencies updated to use containers:

  • all
  • deploy_kind
  • push

As a precursor to supporting Windows builds, I'm separating out
more parts of our build in CircleCI.

Major changes:
 - unit tests in parallel with other build steps
 - separate building the binaries, building the images, and running
integration tests
 - using workspaces to persist binaries/images across jobs

Total time to run the workflow decreased by about 3m (30%) since
the unit tests were no longer on the critical path.

Signed-off-by: John Schnake <jschnake@vmware.com>
@johnSchnake johnSchnake merged commit 248e819 into vmware-tanzu:master Feb 4, 2020
@johnSchnake johnSchnake deleted the useBuildWorkspaces branch February 4, 2020 20:25
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.

2 participants