volcano icon indicating copy to clipboard operation
volcano copied to clipboard

Optimize CI with reusable image workflow

Open Deepam02 opened this issue 2 weeks ago • 15 comments

What this PR does / why we need it:

This PR optimizes the CI pipeline by extracting Docker image building into a centralized reusable workflow. Previously, each E2E test job built images independently, resulting in redundant builds and wasted resources.

Changes:

  • Created images.yaml as a reusable workflow that builds all Volcano Docker images once
  • Saves built images as artifacts
  • Updated all 10 E2E workflows to download and load pre-built images instead of rebuilding
  • Uses standard docker save/docker load commands for artifact handling

Benefits:

  • Eliminates redundant image builds across parallel jobs
  • Significantly reduces CI execution time and resource usage
  • Faster feedback loop when retriggering failed pipelines
  • Images are built once and reused across all test jobs

Which issue(s) this PR fixes:

Fixes #4766

Special notes for your reviewer:

The implementation follows GitHub's reusable workflow pattern. All E2E workflows now have a needs: build-images dependency and download artifacts before running tests. The existing test infrastructure remains unchanged - only the image provisioning mechanism has been optimized.

Deepam02 avatar Dec 04 '25 19:12 Deepam02

[!NOTE] Gemini is unable to generate a summary for this pull request due to the file types involved not being currently supported.

gemini-code-assist[bot] avatar Dec 04 '25 19:12 gemini-code-assist[bot]

Welcome @Deepam02! It looks like this is your first PR to volcano-sh/volcano 🎉

volcano-sh-bot avatar Dec 04 '25 19:12 volcano-sh-bot

/cc @hajnalmt

JesseStutler avatar Dec 05 '25 06:12 JesseStutler

Hi @hajnalmt I have made all the suggested changes, squashed the commits, and rebased. Sorry for the delay in getting this done, please review it again when you get time.

Deepam02 avatar Dec 08 '25 05:12 Deepam02

@hajnalmt

I've restructured the workflows as suggested:

  • Created a new e2e.yaml orchestrator that calls images.yaml first, then triggers all E2E workflows in parallel

CI should be green now. Please review when you have a chance.

Deepam02 avatar Dec 08 '25 13:12 Deepam02

/unhold

Thank you! Let's see :)

hajnalmt avatar Dec 08 '25 13:12 hajnalmt

@hajnalmt: No presubmit jobs available for volcano-sh/volcano@master

In response to this:

/test all

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

volcano-sh-bot avatar Dec 08 '25 13:12 volcano-sh-bot

/retest

hajnalmt avatar Dec 08 '25 13:12 hajnalmt

/ok-to-test cancel

hajnalmt avatar Dec 08 '25 13:12 hajnalmt

/cc @JesseStutler

Can you trigger testing somehow on this one? We probably need to remove the ok-to-test label and readd it since the workflow structure changed.

hajnalmt avatar Dec 08 '25 13:12 hajnalmt

/rerun-all

hajnalmt avatar Dec 08 '25 13:12 hajnalmt

/cc @JesseStutler

Can you trigger testing somehow on this one? We probably need to remove the ok-to-test label and readd it since the workflow structure changed.

/ok-to-test label is enough

JesseStutler avatar Dec 09 '25 03:12 JesseStutler

Seems that all the CIs have triggered but some CIs failed such as e2e-spark and e2e-vcctl, some failed CIs event can't load images @Deepam02 But why we still have pending checks here? image Shouldn't we already have some CIs passed and don't need to execute the independent old CIs again?

JesseStutler avatar Dec 09 '25 08:12 JesseStutler

What's more, you still have built all the images in each workflow: image But what we want is that we just need to build the images only once, and load to the kind clusters in each workflow. @Deepam02

JesseStutler avatar Dec 09 '25 08:12 JesseStutler

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Once this PR has been reviewed and has the lgtm label, please assign wangyang0616 for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment Approvers can cancel approval by writing /approve cancel in a comment

volcano-sh-bot avatar Dec 09 '25 09:12 volcano-sh-bot