Skip to content

feat(assembly): add Docker image build support via Maven profile (#1701)#1757

Open
jbonofre wants to merge 3 commits intoapache:mainfrom
jbonofre:gh-1701
Open

feat(assembly): add Docker image build support via Maven profile (#1701)#1757
jbonofre wants to merge 3 commits intoapache:mainfrom
jbonofre:gh-1701

Conversation

@jbonofre
Copy link
Member

This closes #1701

@jbonofre jbonofre requested a review from jeanouii March 12, 2026 05:36
Copy link
Contributor

@jeanouii jeanouii left a comment

Choose a reason for hiding this comment

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

LGTM

Small comments regarding the plugin versions and the goal=push for the profile.
Wondering if it's meant to replace the previous script and therefor if we should have the script deleted along side these changes to address the issue.
The dockerfile is out side this PR scope, but it would be great to pass in the Java version instead of having it hard coded (so we can use 17/21 or 25).
In terms of versioning, we probably also need latest to be created and have the git tag somewhere.

High level thoughts. hopefully it helps

<plugin>
<groupId>io.fabric8</groupId>
<artifactId>docker-maven-plugin</artifactId>
<version>0.45.1</version>
Copy link
Contributor

Choose a reason for hiding this comment

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

We use the version twice. Not a blocker, but would be better to extract it and reuse it.

Copy link
Contributor

Choose a reason for hiding this comment

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

Also do we need goal -> push?
The docker images are built locally but never pushed, right?

Copy link
Member Author

Choose a reason for hiding this comment

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

We need the push for buildx to be able to do multi-platform images.

That's the different between "local" (building the Docker image for the local host platform) and the "push" that actually do multi-platforms image (linux/amd64 and linux/arm64).

Good point for the plugin version, I will create a property to avoid the duplicate.

@jbonofre
Copy link
Member Author

  1. The previous build.sh is not used anymore. I kept for "transition" purpose but I'm fine to delete it (to avoid confusion).
  2. Good point about the Java version, let me improve this.
  3. Let me create the latest alias too.

Thanks @jeanouii !

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.

Create docker image as part of the build

2 participants