johnpoth opened a new pull request #2383:
URL: https://github.com/apache/camel-k/pull/2383


   <!-- Description -->
   
   Solves #2132 and part of #1227. To use Maven dependencies hosted in a S3 
repository the workflow would be something like this:
   
   
   
   1. Create a custom Maven _settings.xml_ as a _Secret_ in Kubernetes 
containing the S3 credentials & host information:
   
   ```
   <servers>
     <server>
       <id>minio-release</id>
       <username>291cafe6-eceb-43dc-91b3-58be867d9da2</username>
       <password>e383fed0-4645-45f6-acea-65f3748b96c8</password>
       <configuration>
         <wagonProvider>s3</wagonProvider>
         <s3Provider>minio</s3Provider>
         
<endpoint>https://minio-tenant-1-hl.minio-tenant-1.svc.cluster:4430</endpoint>
       </configuration>
     </server>
     <server>
       <id>minio-snapshot</id>
       <username>291cafe6-eceb-43dc-91b3-58be867d9da2</username>
       <password>e383fed0-4645-45f6-acea-65f3748b96c8</password>
       <configuration>
         <wagonProvider>s3</wagonProvider>
         <s3Provider>minio</s3Provider>
         
<endpoint>https://minio-tenant-1-hl.minio-tenant-1.svc.cluster:4430</endpoint>
       </configuration>
     </server>
   </servers>
   ```
   
   ...
   ```
   <repositories>
     <repository>
       <id>minio-release</id>
       <name>MinIO Release Repository</name>
       <url>s3://maven/release</url>
     </repository>
     <repository>
       <id>minio-snapshot</id>
       <name>MinIO Snapshot Repository</name>
       <url>s3://maven/snapshot</url>
     </repository>
   </repositories>
   ```
   
   2. Optionally create the S3 repository CA as a _Secret_ in Kubernetes
   3.  Reference all the above plus the S3 wagon when installing camel-k, so 
something like:
   `kamel install --maven-settings 
secret:camel-k-minio-maven-settings/maven-settings --maven-ca-secret 
minio-ca/minio-ca --maven-build-extension fi.yle.tools:aws-maven:1.4.2`
   4. Reference the dependencies hosted in S3 just like any other dependencies 
e.g 
   `kamel run examples/languages/Sample.java --dependency=mvn:hosted:ons3:1.1
   
   Tested with MinIO operator 4.0.11
   
   Thanks !
   
   
   <!--
   Enter your extended release note in the below block. If the PR requires
   additional action from users switching to the new release, include the string
   "action required". If no release note is required, write "NONE". 
   
   You can (optionally) mark this PR with labels "kind/bug" or "kind/feature" 
to make sure
   the text is added to the right section of the release notes. 
   -->
   
   **Release Note**
   ```release-note
   NONE
   ```
   


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

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to