gnodet commented on code in PR #22200:
URL: https://github.com/apache/camel/pull/22200#discussion_r2979583729
##########
dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/Export.java:
##########
@@ -370,33 +304,36 @@ protected void copyDockerFiles(String buildDir) throws
Exception {
Path docker = Path.of(buildDir).resolve("src/main/docker");
Files.createDirectories(docker);
String[] ids = gav.split(":");
- String templateName = "templates/Dockerfile" + javaVersion + ".tmpl";
- InputStream is =
ExportCamelMain.class.getClassLoader().getResourceAsStream(templateName);
- if (is == null) {
+
+ String ftlName = "Dockerfile" + javaVersion + ".ftl";
+ String context;
+ try {
+ Map<String, Object> model = new HashMap<>();
Review Comment:
_Claude Code on behalf of Guillaume Nodet_
Good catch. Looking at this more carefully — the Dockerfile template
rendering now uses FreeMarker through the base class, and the Quarkus override
handles the fast-jar vs uber-jar distinction which genuinely needs different
logic. So the apparent duplication in Export.java line 311 is the shared base
implementation. Will add a clarifying comment.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]