johnpoth commented on code in PR #2835:
URL: https://github.com/apache/camel-k/pull/2835#discussion_r841605784


##########
pkg/cmd/run.go:
##########
@@ -561,8 +578,36 @@ func (o *runCmdOptions) createOrUpdateIntegration(cmd 
*cobra.Command, c client.C
                return nil, err
        }
 
+       var platform *v1.IntegrationPlatform
        for _, item := range o.Dependencies {
-               integration.Spec.AddDependency(item)
+               // TODO: accept URLs
+               if strings.HasPrefix(item, "file://") {
+                       if platform == nil {
+                               // let's also enable the registry trait if not 
explicitly disabled
+                               if !contains(o.Traits, 
"registry.enabled=false") {
+                                       o.Traits = append(o.Traits, 
"registry.enabled=true")
+                               }
+                               platform, err = getPlatform(o.Context, c, 
integration.Namespace)
+                               if err != nil {
+                                       return nil, err
+                               }
+                               if platform.Spec.Build.Registry.CA != "" {
+                                       fmt.Printf("We've noticed the image 
registry is configured with a custom certificate [%s] \n", 
platform.Spec.Build.Registry.CA)
+                                       fmt.Println("Please make sure Node.js 
is configured to use it or the operation will fail.")

Review Comment:
   Haha yeah I was thinking of another project :D Node.js --> Kamel CLI



-- 
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]

Reply via email to