This is an automated email from the ASF dual-hosted git repository.

marat pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-karavan.git


The following commit(s) were added to refs/heads/main by this push:
     new a8e5094c Fix #929
a8e5094c is described below

commit a8e5094c6e4ae278a79f5561f8be7f683157e59e
Author: Marat Gubaidullin <ma...@talismancloud.io>
AuthorDate: Fri Oct 20 21:51:49 2023 -0400

    Fix #929
---
 .../java/org/apache/camel/karavan/installer/Constants.java |  2 +-
 .../org/apache/camel/karavan/installer/KaravanCommand.java | 14 ++++++++------
 .../karavan/installer/resources/KaravanDeployment.java     |  3 +++
 3 files changed, 12 insertions(+), 7 deletions(-)

diff --git 
a/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/Constants.java
 
b/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/Constants.java
index 49a3b49d..17ac8dc3 100644
--- 
a/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/Constants.java
+++ 
b/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/Constants.java
@@ -27,7 +27,7 @@ public final class Constants {
     public static final String  DEFAULT_GIT_BRANCH = "main";
 
     public static final String DEFAULT_IMAGE_REGISTRY_OPENSHIFT = 
"image-registry.openshift-image-registry.svc:5000";
-    public static final String DEFAULT_BUILD_IMAGE = 
"ghcr.io/apache/camel-karavan-devmode";
+    public static final String DEFAULT_DEVMODE_IMAGE = 
"ghcr.io/apache/camel-karavan-devmode";
 
     public static final String KARAVAN_IMAGE = "ghcr.io/apache/camel-karavan";
 
diff --git 
a/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/KaravanCommand.java
 
b/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/KaravanCommand.java
index 415fa1b9..50da82a6 100644
--- 
a/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/KaravanCommand.java
+++ 
b/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/KaravanCommand.java
@@ -43,8 +43,8 @@ public class KaravanCommand implements Callable<Integer> {
     private int nodePort;
     @CommandLine.Option(names = {"--image"}, description = "Karavan Image", 
defaultValue = Constants.KARAVAN_IMAGE)
     private String baseImage;
-    @CommandLine.Option(names = {"--builder-image"}, description = "Karavan 
Base Builder Image", defaultValue = Constants.DEFAULT_BUILD_IMAGE)
-    private String baseBuilderImage;
+    @CommandLine.Option(names = {"--devmode-image"}, description = "Karavan 
DevMode Image", defaultValue = Constants.DEFAULT_DEVMODE_IMAGE)
+    private String devmodeImage;
     @CommandLine.Option(names = {"--file"}, description = "YAML file name", 
defaultValue = "karavan.yaml")
     private String file;
     @CommandLine.Option(names = {"--yaml"}, description = "Create YAML file. 
Do not apply")
@@ -112,7 +112,9 @@ public class KaravanCommand implements Callable<Integer> {
     @Override
     public Integer call() throws Exception {
         if (yaml) {
+            System.out.println("⭕  Preparing Karavan resources YAML");
             Files.writeString(Path.of(file), 
ResourceUtils.generateResources(this));
+            System.out.println("\uD83D\uDC4D Prepared Karavan resources YAML " 
+ file);
         } else {
             CommandUtils.installKaravan(this);
         }
@@ -199,12 +201,12 @@ public class KaravanCommand implements Callable<Integer> {
         this.baseImage = baseImage;
     }
 
-    public String getBaseBuilderImage() {
-        return baseBuilderImage;
+    public String getDevmodeImage() {
+        return devmodeImage;
     }
 
-    public void setBaseBuilderImage(String baseBuilderImage) {
-        this.baseBuilderImage = baseBuilderImage;
+    public void setDevmodeImage(String devmodeImage) {
+        this.devmodeImage = devmodeImage;
     }
 
     public String getFile() {
diff --git 
a/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/resources/KaravanDeployment.java
 
b/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/resources/KaravanDeployment.java
index 73204afb..846d604a 100644
--- 
a/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/resources/KaravanDeployment.java
+++ 
b/karavan-web/karavan-installer/src/main/java/org/apache/camel/karavan/installer/resources/KaravanDeployment.java
@@ -51,6 +51,9 @@ public class KaravanDeployment {
         envVarList.add(
                 new EnvVar("KARAVAN_CAMEL_STATUS_INTERVAL", "3s", null)
         );
+        envVarList.add(
+                new EnvVar("KARAVAN_DEVMODE_IMAGE", config.getDevmodeImage(), 
null)
+        );
         envVarList.add(
                 new EnvVar("INFINISPAN_HOSTS", "infinispan." + 
config.getNamespace() + ":11222", null)
         );

Reply via email to