You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "christophd (via GitHub)" <gi...@apache.org> on 2024/03/27 09:03:32 UTC

[I] Build configuration on IntegrationPlatform ignored [camel-k]

christophd opened a new issue, #5289:
URL: https://github.com/apache/camel-k/issues/5289

   ### What happened?
   
   The IntegrationPlatform spec is able to hold build configuration settings that should be applied to the integration image builds. However, some settings are ignored when set on the IntegrationPlatform (e.g. `build.buildConfiguration.platforms`).
   
   Status of the Integration platform after adding the setting:
   ```yaml
   #...
     status:
       build:
         baseImage: arm64v8/eclipse-temurin:17
         buildConfiguration:
           orderStrategy: sequential
           platforms:
           - linux/amd64
           - linux/arm64
           strategy: routine
   #...
   ```
   
   I would expect the operator to use a setting `-Djib.from.platforms=linux/arm64` but it is not there (see logs below).
   
   When the platform is set via trait option on the integration (`kamel run simple.groovy -t builder.platforms="linux/arm64"`) it works and I can see the setting `-Djib.from.platforms=linux/arm64` is being used during the integration image build as expected.
   
   Users should be able to set this also on IntegrationPlatform level for all integrations.
   
   ### Steps to reproduce
   
   1. Install Camel K 2.3.0-SNAPSHOT
   2. patch the IntegrationPlatform to add build configuration (`k patch itp camel-k --type=merge -p '{"spec":{"build": { "buildConfiguration": {"platforms": ["linux/amd64","linux/arm64"]}}}}'`)
   3. Review the integration platform status to have the setting applied
   4. run integration and review the operator log to use the setting `-Djib.from.platforms=linux/arm64` during the build
   
   ### Relevant log output
   
   ```shell
   {"level":"info","ts":"2024-03-27T08:49:31Z","logger":"camel-k.maven.build","msg":"Executed command: ./mvnw jib:build -V --no-transfer-progress -Dstyle.color=never -Dmaven.repo.local=/etc/maven/m2 --global-settings /tmp/kit-co1tqo3ui44s7386ui00-557093953/maven/settings.xml -Dmaven.artifact.threads=4 -T 4 -P jib -Djib.to.image=10.96.46.247/camel-system/camel-k-kit-co1tqo3ui44s7386ui00:39034 -Djib.from.image=arm64v8/eclipse-temurin:17 -Djib.allowInsecureRegistries=true"}
   ```
   
   
   ### Camel K version
   
   2.3.0-SNAPSHOT


-- 
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-unsubscribe@camel.apache.org.apache.org

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


Re: [I] Build configuration on IntegrationPlatform ignored [camel-k]

Posted by "squakez (via GitHub)" <gi...@apache.org>.
squakez commented on issue #5289:
URL: https://github.com/apache/camel-k/issues/5289#issuecomment-2063971057

   Ah, I think I miss to read the second part, like it fails to execute when the property are set outside the trait. Gonna checking right now.


-- 
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-unsubscribe@camel.apache.org

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


Re: [I] Build configuration on IntegrationPlatform ignored [camel-k]

Posted by "squakez (via GitHub)" <gi...@apache.org>.
squakez commented on issue #5289:
URL: https://github.com/apache/camel-k/issues/5289#issuecomment-2063950430

   @christophd are you sure this is happening with version 2.3.0? Just tested and it work as expected:
   ```
   kamel run test.yaml -t builder.platforms="linux/arm64"
   ...
   camel-k-operator-56cbd4ff78-h4z5g camel-k-operator {"level":"info","ts":"2024-04-18T14:01:34Z","logger":"camel-k.maven.build","msg":"Executed command: ./mvnw jib:build -V --no-transfer-progress -Dstyle.color=never -Dmaven.repo.local=/etc/maven/m2 --global-settings /tmp/kit-cogif7of9h2c73aouqu0-2355704660/maven/settings.xml -Dmaven.artifact.threads=8 -T 8 -P jib -Djib.to.image=10.103.186.147/default/camel-k-kit-cogif7of9h2c73aouqu0:1233624 -Djib.from.image=eclipse-temurin:17 -Djib.baseImageCache=/tmp/kit-cogif7of9h2c73aouqu0-2355704660/maven/jib -Djib.from.platforms=linux/arm64 -Djib.allowInsecureRegistries=true"}
   ....
   $ docker inspect 69cdd648323b
   ...
           "Architecture": "arm64",
           "Os": "linux",
   ```


-- 
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-unsubscribe@camel.apache.org

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


Re: [I] Build configuration on IntegrationPlatform ignored [camel-k]

Posted by "squakez (via GitHub)" <gi...@apache.org>.
squakez closed issue #5289: Build configuration on IntegrationPlatform ignored
URL: https://github.com/apache/camel-k/issues/5289


-- 
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-unsubscribe@camel.apache.org

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