You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2022/02/03 17:19:41 UTC
[camel-kamelets] 01/06: Support DefaultCredentialProvider in the AWS Kamelets - AWS EC2
This is an automated email from the ASF dual-hosted git repository.
acosentino pushed a commit to branch support-cred
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git
commit 05732e27a82a9822f5391fe387da0222b57c0960
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Thu Feb 3 14:07:28 2022 +0100
Support DefaultCredentialProvider in the AWS Kamelets - AWS EC2
---
kamelets/aws-ec2-sink.kamelet.yaml | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)
diff --git a/kamelets/aws-ec2-sink.kamelet.yaml b/kamelets/aws-ec2-sink.kamelet.yaml
index c465ab3..79259e0 100644
--- a/kamelets/aws-ec2-sink.kamelet.yaml
+++ b/kamelets/aws-ec2-sink.kamelet.yaml
@@ -33,12 +33,14 @@ spec:
description: |-
Check the status of EC2 instances
+ Access Key/Secret Key are the basic method for authenticating to the AWS EC2 Service. These parameters are optional, because the Kamelet provide also the 'useDefaultCredentialsProvider'.
+
+ When using a default Credentials Provider the EC2 client will load the credentials through this provider and won't use the static credential. This is reason for not having the access key and secret key as mandatory parameter for this Kamelet.
+
The Kamelet expects the following headers to be set:
- `instanceIds` / `ce-instanceids`: as a comma separated list of EC2 instance ids.
required:
- - accessKey
- - secretKey
- region
type: object
properties:
@@ -63,6 +65,13 @@ spec:
description: The AWS region to connect to
type: string
example: eu-west-1
+ useDefaultCredentialsProvider:
+ title: Default Credentials Provider
+ description: Set whether the S3 client should expect to load credentials through a default credentials provider or to expect static credentials to be passed in.
+ type: boolean
+ x-descriptors:
+ - 'urn:alm:descriptor:com.tectonic.ui:checkbox'
+ default: false
dependencies:
- "camel:core"
- "camel:aws2-ec2"
@@ -86,7 +95,8 @@ spec:
- to:
uri: "aws2-ec2:ec2-route"
parameters:
- accessKey: "{{accessKey}}"
- secretKey: "{{secretKey}}"
+ accessKey: "{{?accessKey}}"
+ secretKey: "{{?secretKey}}"
region: "{{region}}"
operation: "describeInstancesStatus"
+ useDefaultCredentialsProvider: "{{useDefaultCredentialsProvider}}"