Skip to content

Conversation

@MinerYang
Copy link
Contributor

@MinerYang MinerYang commented Jul 3, 2025

Thank you for contributing to Harbor!

Comprehensive Summary of your change

add BUILD_INSTALLER parameter to optional build prepare and log container when only need build offline_installer

Issue being fixed

Fixes #(issue)

Please indicate you've done the following:

  • Well Written Title and Summary of the PR
  • Label the PR as needed. "release-note/ignore-for-release, release-note/new-feature, release-note/update, release-note/enhancement, release-note/community, release-note/breaking-change, release-note/docs, release-note/infra, release-note/deprecation"
  • Accepted the DCO. Commits without the DCO will delay acceptance.
  • Made sure tests are passing and test coverage is added if needed.
  • Considered the docs impact and opened a new docs issue or PR with docs changes if needed in website repository.

@MinerYang MinerYang requested a review from a team as a code owner July 3, 2025 07:45
@MinerYang MinerYang added the release-note/update Update or Fix label Jul 3, 2025
@MinerYang MinerYang changed the title add BUILD_INSTALLER parameter to optional build prepare and log conta… add BUILD_INSTALLER parameter for optionally build prepare and log container Jul 3, 2025
@codecov
Copy link

codecov bot commented Jul 3, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 65.87%. Comparing base (c8c11b4) to head (8eb9ff5).
Report is 504 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##             main   #22148       +/-   ##
===========================================
+ Coverage   45.36%   65.87%   +20.50%     
===========================================
  Files         244     1072      +828     
  Lines       13333   115713   +102380     
  Branches     2719     2925      +206     
===========================================
+ Hits         6049    76226    +70177     
- Misses       6983    35262    +28279     
- Partials      301     4225     +3924     
Flag Coverage Δ
unittests 65.87% <ø> (+20.50%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

see 986 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@MinerYang MinerYang force-pushed the make-offline-installer-optional branch 2 times, most recently from 6e97fd9 to a2c783a Compare July 3, 2025 07:55
@reasonerjt reasonerjt requested a review from Copilot July 3, 2025 08:36
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Add a BUILD_INSTALLER flag to control whether the prepare and log containers are built and included in the offline installer.

  • Introduce a conditional buildcompt target in make/photon/Makefile to skip _build_prepare and _build_log when BUILD_INSTALLER=false
  • Update BUILDBASETARGET and DOCKERSAVE_PARA in the top-level Makefile to respect the new flag and pass it into build containers
  • Add a check_buildinstaller guard for the package_offline target to enforce BUILD_INSTALLER=true

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
make/photon/Makefile Replace hardcoded build: dependencies with a conditional buildcompt based on BUILD_INSTALLER
Makefile Default BUILD_INSTALLER=true, adjust BUILDBASETARGET, DOCKERSAVE_PARA, expose flag in build container, and guard the package_offline target
Comments suppressed due to low confidence (2)

make/photon/Makefile:237

  • [nitpick] The target name 'buildcompt' is ambiguous; consider renaming it to a more descriptive name like 'build_components' for clarity.
buildcompt: _build_prepare _build_db _build_portal _build_core _build_jobservice _build_log _build_nginx _build_registry _build_registryctl _build_trivy_adapter _build_redis _compile_and_build_exporter

Makefile:458

  • [nitpick] Consider rephrasing this error message to 'BUILD_INSTALLER must be set to "true" to use package_offline target' for better readability.
		echo "Must set BUILD_INSTALLER as true while triggering package_offline build" ; \

Copy link
Contributor

@wy65701436 wy65701436 left a comment

Choose a reason for hiding this comment

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

lgtm

…tainer only when we need to build offline_installer

Signed-off-by: my036811 <[email protected]>
@MinerYang MinerYang force-pushed the make-offline-installer-optional branch from a2c783a to 8eb9ff5 Compare July 3, 2025 09:41
@MinerYang MinerYang merged commit 2565491 into goharbor:main Jul 3, 2025
12 checks passed
AYDEV-FR pushed a commit to AYDEV-FR/harbor that referenced this pull request Jul 4, 2025
…ntainer (goharbor#22148)

add BUILD_INSTALLER parameter to optionally build prepare and log container only when we need to build offline_installer

Signed-off-by: my036811 <[email protected]>
Signed-off-by: AYDEV-FR <[email protected]>
OrlinVasilev pushed a commit to OrlinVasilev/harbor that referenced this pull request Oct 29, 2025
…ntainer (goharbor#22148)

add BUILD_INSTALLER parameter to optionally build prepare and log container only when we need to build offline_installer

Signed-off-by: my036811 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release-note/update Update or Fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants