claudio4j commented on code in PR #4680:
URL: https://github.com/apache/camel-k/pull/4680#discussion_r1305035712


##########
pkg/builder/project.go:
##########
@@ -195,13 +195,19 @@ func sanitizeDependencies(ctx *builderContext) error {
        return 
camel.SanitizeIntegrationDependencies(ctx.Maven.Project.Dependencies)
 }
 
-func injectProfile(ctx *builderContext) error {
-       val, err := kubernetes.ResolveValueSource(ctx.C, ctx.Client, 
ctx.Namespace, &ctx.Build.Maven.Profile)
-       if err != nil {
-               return err
-       }
-       if val != "" {
-               ctx.Maven.Project.AddProfile(val)
+func injectProfiles(ctx *builderContext) error {
+       if ctx.Build.Maven.Profiles != nil {
+               profiles := ""
+               for i := range ctx.Build.Maven.Profiles {
+                       val, err := kubernetes.ResolveValueSource(ctx.C, 
ctx.Client, ctx.Namespace, &ctx.Build.Maven.Profiles[i])
+                       if err != nil {
+                               return err

Review Comment:
   WDYT to return or print in the log a more descriptive error message about 
not able to load the configmap profile ?



-- 
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: commits-unsubscr...@camel.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to