Skip to content

dockerfiles: Install minimum components and avoiding to use includeRecommended#11477

Open
cosmo0920 wants to merge 1 commit intomasterfrom
cosmo0920-install-with-minimum-components-on-windows-image-building
Open

dockerfiles: Install minimum components and avoiding to use includeRecommended#11477
cosmo0920 wants to merge 1 commit intomasterfrom
cosmo0920-install-with-minimum-components-on-windows-image-building

Conversation

@cosmo0920
Copy link
Contributor

@cosmo0920 cosmo0920 commented Feb 18, 2026


Enter [N/A] in the box, if an item is not applicable to your change.

Testing
Before we can approve your change; please submit the following in a comment:

  • Example configuration file for the change
  • Debug log output from testing the change
  • Attached Valgrind output that shows no leaks or memory corruption was found

If this is a change to packaging of containers or native binaries then please confirm it works for all targets.

  • Run local packaging test showing all targets (including any new ones) build.
  • Set ok-package-test label to test for all targets (requires maintainer to do).

Documentation

  • Documentation required for this feature

Backporting

  • Backport to latest stable release.

Fluent Bit is licensed under Apache 2.0, by submitting this pull request I understand that this code will be released under the terms of that license.

Summary by CodeRabbit

  • Chores
    • Updated Windows build environment to install specific Visual C++ components (explicit VC toolchain pieces) and the Windows 10 SDK, replacing prior workload-based install flags.
    • Configured vcpkg to use the explicit Visual Studio build tools path (VCPKG_VISUAL_STUDIO_PATH) under release builds, ensuring native dependency installs run within the intended Visual C++ environment and improving reliability of Windows image builds.

@coderabbitai
Copy link

coderabbitai bot commented Feb 18, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Replaces workload-based Visual Studio Build Tools install with explicit components (VC.Tools.x86.x64, VC.CoreBuildTools, VC.MSVC.143, Windows10SDK.19041), reorders -NoNewWindow -Wait, and adds VCPKG_VISUAL_STUDIO_PATH="C:\BuildTools" in the vcpkg VCPKG_BUILD_TYPE=release block.

Changes

Cohort / File(s) Summary
Windows Dockerfile
dockerfiles/Dockerfile.windows
Replaced --add Microsoft.VisualStudio.Workload.VCTools with explicit components VC.Tools.x86.x64, VC.CoreBuildTools, VC.MSVC.143, Windows10SDK.19041; moved -NoNewWindow -Wait placement in the install command. Added VCPKG_VISUAL_STUDIO_PATH="C:\BuildTools" under the VCPKG_BUILD_TYPE=release vcpkg setup block.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Suggested labels

docs-required

Suggested reviewers

  • niedbalski
  • patrick-stephens
  • celalettin1286

Poem

🐰 I hopped through Docker, tidy and neat,
swapped bits and paths to make builds complete.
Components aligned, BuildTools in place,
vcpkg now finds its cozy base. 🥕

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: modifying Dockerfile components to install minimum Visual Studio Build Tools components instead of the broader workload installation.
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 unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch cosmo0920-install-with-minimum-components-on-windows-image-building

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@cosmo0920 cosmo0920 added ok-package-test Run PR packaging tests and removed docs-required labels Feb 18, 2026
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@dockerfiles/Dockerfile.windows`:
- Around line 49-52: The Dockerfile currently adds the unversioned
Microsoft.VisualStudio.Component.Windows10SDK which only installs the Universal
C Runtime and, because --includeRecommended was removed, the full Windows SDK
(headers/libs) is missing; replace the unversioned component with a versioned
full SDK component such as Microsoft.VisualStudio.Component.Windows10SDK.20348
or Microsoft.VisualStudio.Component.Windows11SDK.26100 in the same install list
(next to Microsoft.VisualStudio.Component.VC.Tools.x86.x64) so the build gets
the full headers/libraries required for CMake/NMake C++ builds.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
dockerfiles/Dockerfile.windows (1)

49-52: Component IDs are valid; consider a newer Windows SDK for the ltsc2025 base image.

Microsoft.VisualStudio.Component.VC.Tools.x86.x64 and Microsoft.VisualStudio.Component.Windows10SDK.19041 are both listed as valid Optional components in the VS Build Tools 2022 component directory (17.14.36015.10). The explicit addition of VC.Tools.x86.x64 is the correct way to ensure the MSVC compiler is installed without --includeRecommended.

One minor consideration: the base image is ltsc2025 (Windows Server 2025), and Windows10SDK.19041 (10.0.19041.0, May 2020) is a noticeably older SDK than what --includeRecommended would have pulled in. For recent releases, use of a Windows 11 SDK or later is strongly recommended. If Fluent Bit's build or any dependency ever needs a newer API surface, a one-line bump to e.g. Windows11SDK.26100 would be needed. 19041 is sufficient for the current build, but the delta is worth being intentional about.

🔧 Optional: bump to a newer SDK family
-      '--add Microsoft.VisualStudio.Component.Windows10SDK.19041', `
+      '--add Microsoft.VisualStudio.Component.Windows11SDK.26100', `
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@dockerfiles/Dockerfile.windows` around lines 49 - 52, The Dockerfile.windows
currently installs Microsoft.VisualStudio.Component.Windows10SDK.19041 which is
older than appropriate for the ltsc2025 base image; update the SDK component to
a newer Windows 11 SDK (for example replace
Microsoft.VisualStudio.Component.Windows10SDK.19041 with
Microsoft.VisualStudio.Component.Windows11SDK.26100) in the same install command
that includes Microsoft.VisualStudio.Workload.VCTools and
Microsoft.VisualStudio.Component.VC.Tools.x86.x64 so the MSVC toolchain stays
installed and the SDK targets a newer API surface compatible with ltsc2025.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@dockerfiles/Dockerfile.windows`:
- Around line 49-52: The Dockerfile.windows currently installs
Microsoft.VisualStudio.Component.Windows10SDK.19041 which is older than
appropriate for the ltsc2025 base image; update the SDK component to a newer
Windows 11 SDK (for example replace
Microsoft.VisualStudio.Component.Windows10SDK.19041 with
Microsoft.VisualStudio.Component.Windows11SDK.26100) in the same install command
that includes Microsoft.VisualStudio.Workload.VCTools and
Microsoft.VisualStudio.Component.VC.Tools.x86.x64 so the MSVC toolchain stays
installed and the SDK targets a newer API surface compatible with ltsc2025.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@dockerfiles/Dockerfile.windows`:
- Around line 150-153: The PowerShell Docker RUN lines call cmd /C "call
%MSVS_HOME%\VC\Auxiliary\Build\vcvars64.bat && vcpkg install ..." but do not
propagate cmd's non‑zero exit to the PowerShell process, so vcpkg failures are
swallowed; after each cmd invocation (the lines using cmd /S /C "call ... &&
vcpkg install ...") add an explicit check of $LASTEXITCODE and if it is non‑zero
call exit $LASTEXITCODE (or throw) before running the subsequent Remove-Item
cleanup statements so the Docker build fails when vcpkg fails; apply the same
change to the other similar cmd invocation block referenced in the comment (the
lines around the second vcpkg install).

@cosmo0920 cosmo0920 force-pushed the cosmo0920-install-with-minimum-components-on-windows-image-building branch from e2771ab to d11a6f6 Compare February 18, 2026 08:36
@cosmo0920 cosmo0920 force-pushed the cosmo0920-install-with-minimum-components-on-windows-image-building branch from d11a6f6 to 5089ffc Compare February 18, 2026 08:37
@cosmo0920 cosmo0920 force-pushed the cosmo0920-install-with-minimum-components-on-windows-image-building branch from 5089ffc to b3964e3 Compare February 18, 2026 08:38
@cosmo0920 cosmo0920 force-pushed the cosmo0920-install-with-minimum-components-on-windows-image-building branch from 21fa13e to 93a663a Compare February 18, 2026 09:04
@cosmo0920 cosmo0920 force-pushed the cosmo0920-install-with-minimum-components-on-windows-image-building branch from 93a663a to fe62dfc Compare February 18, 2026 09:07
@cosmo0920 cosmo0920 force-pushed the cosmo0920-install-with-minimum-components-on-windows-image-building branch from fe62dfc to 1fa60ea Compare February 18, 2026 09:10
@cosmo0920 cosmo0920 force-pushed the cosmo0920-install-with-minimum-components-on-windows-image-building branch from 1fa60ea to 96162ba Compare February 18, 2026 09:12
…commended

Signed-off-by: Hiroshi Hatake <hiroshi@chronosphere.io>
@cosmo0920
Copy link
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ok-package-test Run PR packaging tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

Comments