Skip to content

[DX-3066] Don't skip private plugins when building the image#2458

Merged
Tofel merged 5 commits intomainfrom
dx-3066-plugins-image
Mar 4, 2026
Merged

[DX-3066] Don't skip private plugins when building the image#2458
Tofel merged 5 commits intomainfrom
dx-3066-plugins-image

Conversation

@Tofel
Copy link
Contributor

@Tofel Tofel commented Mar 3, 2026

This pull request updates the Docker image build process to use Docker Buildx instead of the standard Docker build command, and removes the explicit setting of the CL_INSTALL_PRIVATE_PLUGINS environment variable to false. It also adds support for passing a GitHub token as a build secret if available.

Docker build process improvements:

  • Switches from docker build to docker buildx build for building images, enabling advanced build features and better cross-platform support.
  • Removes the CL_INSTALL_PRIVATE_PLUGINS=false build argument, so it is no longer set by default during image builds. [1] [2]
  • Adds support for passing the GITHUB_TOKEN as a build secret (--secret id=GIT_AUTH_TOKEN,env=GITHUB_TOKEN) if the environment variable is set, improving access to private repositories during the build.

Documentation:

  • Updates the changeset to document the removal of the CL_INSTALL_PRIVATE_PLUGINS variable and the switch to Buildx for Docker image builds.

@Tofel Tofel requested a review from a team as a code owner March 3, 2026 16:57
Copilot AI review requested due to automatic review settings March 3, 2026 16:57
@github-actions
Copy link

github-actions bot commented Mar 3, 2026

👋 Tofel, thanks for creating this pull request!

To help reviewers, please consider creating future PRs as drafts first. This allows you to self-review and make any final changes before notifying the team.

Once you're ready, you can mark it as "Ready for review" to request feedback. Thanks!

Copy link
Contributor

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

Updates local Docker image build behavior to stop forcibly disabling installation of private plugins, and adds optional GitHub token plumbing intended to support authenticated fetches during the Docker build.

Changes:

  • Removes the hard-coded CL_INSTALL_PRIVATE_PLUGINS=false build-arg from docker build invocations.
  • If GITHUB_TOKEN is set, appends a docker build --secret id=GIT_AUTH_TOKEN,env=GITHUB_TOKEN option (both DLV and non-DLV paths).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +427 to +429
if os.Getenv("GITHUB_TOKEN") != "" {
commandParts = append(commandParts, "--secret", "id=GIT_AUTH_TOKEN,env=GITHUB_TOKEN")
}
Copy link

Copilot AI Mar 3, 2026

Choose a reason for hiding this comment

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

docker build --secret ... requires BuildKit; on environments where BuildKit isn't the default, this will fail with "unknown flag: --secret" whenever GITHUB_TOKEN is set (e.g., GitHub Actions). Consider explicitly enabling BuildKit for this invocation (e.g., setting DOCKER_BUILDKIT=1 on the exec.Cmd env) or using a BuildKit-aware builder (docker buildx build), and/or gating --secret behind a BuildKit check.

Copilot uses AI. Check for mistakes.
Comment on lines +437 to +439
if os.Getenv("GITHUB_TOKEN") != "" {
commandParts = append(commandParts, "--secret", "id=GIT_AUTH_TOKEN,env=GITHUB_TOKEN")
}
Copy link

Copilot AI Mar 3, 2026

Choose a reason for hiding this comment

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

Same issue as above: adding --secret will break builds on hosts where BuildKit isn't enabled by default. Prefer explicitly enabling BuildKit for this build command or using a BuildKit builder before appending --secret.

Copilot uses AI. Check for mistakes.
@Tofel Tofel changed the title [DX-3066] Don't skip private plugins [DX-3066] Don't skip private plugins when building the image Mar 4, 2026
skudasov
skudasov previously approved these changes Mar 4, 2026
@Tofel Tofel merged commit fd69a73 into main Mar 4, 2026
73 of 75 checks passed
@Tofel Tofel deleted the dx-3066-plugins-image branch March 4, 2026 10:34
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.

3 participants