Skip to content

fix file upload#57

Merged
bennyz merged 1 commit into
centos-automotive-suite:mainfrom
bennyz:fix-upload
Feb 2, 2026
Merged

fix file upload#57
bennyz merged 1 commit into
centos-automotive-suite:mainfrom
bennyz:fix-upload

Conversation

@bennyz

@bennyz bennyz commented Feb 2, 2026

Copy link
Copy Markdown
Contributor

controller was incorrectly using a volume template

Summary by CodeRabbit

Release Notes

  • Improvements
    • Enhanced image build storage handling with optional reuse of existing storage volumes when the file upload server is enabled
    • Improved dynamic storage provisioning with configurable sizing and storage class selection for greater flexibility

controller was incorrectly using a volume template

Signed-off-by: Benny Zlotnik <bzlotnik@redhat.com>
@coderabbitai

coderabbitai Bot commented Feb 2, 2026

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

This change modifies the PVC/workspace binding strategy in the image build controller, shifting from a mandatory pre-created PVC to a conditional approach that either reuses an existing uploaded-files PVC (when InputFilesServer is enabled) or dynamically creates one via VolumeClaimTemplate with zone affinity support.

Changes

Cohort / File(s) Summary
PVC Binding Logic Refactor
internal/controller/imagebuild/controller.go
Refactored PVC/workspace binding in createBuildTaskRun to conditionally reuse existing PVC for InputFilesServer or dynamically create new PVC via VolumeClaimTemplate with zone affinity, configurable sizing (8Gi default), and optional storage class support.
Dependency Updates
go.mod
Updated Go module dependencies (+29/-14 lines).

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 A workspace PVC tale,
Dynamic binding won't fail!
Reuse or create,
With zone affinity's fate,
The controller grows nimble and hale! ✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Title check ❓ Inconclusive The title 'fix file upload' is vague and generic, using non-descriptive terminology that doesn't clearly convey the specific technical change being made. Consider a more specific title that describes the actual fix, such as 'Rework PVC binding logic for shared workspace' or 'Fix PVC provisioning in image build controller'.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Comment @coderabbitai help to get the list of available commands and usage tips.

@bennyz bennyz merged commit 89b98be into centos-automotive-suite:main Feb 2, 2026
4 checks passed
@bennyz bennyz deleted the fix-upload branch February 2, 2026 10:39
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.

1 participant