Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AWS Kamelets - Support default credentials provider #768

Merged
merged 6 commits into from
Feb 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 14 additions & 4 deletions kamelets/aws-ec2-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand All @@ -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 EC2 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"
Expand All @@ -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}}"
18 changes: 14 additions & 4 deletions kamelets/aws-kinesis-firehose-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,12 @@ spec:
title: AWS Kinesis Firehose Sink
description: |-
Send message to an AWS Kinesis Firehose Stream

Access Key/Secret Key are the basic method for authenticating to the AWS Kinesis Firehose Service. These parameters are optional, because the Kamelet provide also the 'useDefaultCredentialsProvider'.

When using a default Credentials Provider the Kinesis Firehose 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.
required:
- streamName
- accessKey
- secretKey
- region
type: object
properties:
Expand Down Expand Up @@ -64,6 +66,13 @@ spec:
description: The AWS region to connect to
type: string
example: eu-west-1
useDefaultCredentialsProvider:
title: Default Credentials Provider
description: Set whether the Kinesis Firehose 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:aws2-kinesis"
- "camel:kamelet"
Expand All @@ -74,6 +83,7 @@ spec:
- to:
uri: "aws2-kinesis-firehose:{{streamName}}"
parameters:
accessKey: "{{accessKey}}"
secretKey: "{{secretKey}}"
accessKey: "{{?accessKey}}"
secretKey: "{{?secretKey}}"
region: "{{region}}"
useDefaultCredentialsProvider: "{{useDefaultCredentialsProvider}}"
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand All @@ -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 EC2 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"
Expand All @@ -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}}"
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,12 @@ spec:
title: AWS Kinesis Firehose Sink
description: |-
Send message to an AWS Kinesis Firehose Stream

Access Key/Secret Key are the basic method for authenticating to the AWS Kinesis Firehose Service. These parameters are optional, because the Kamelet provide also the 'useDefaultCredentialsProvider'.

When using a default Credentials Provider the Kinesis Firehose 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.
required:
- streamName
- accessKey
- secretKey
- region
type: object
properties:
Expand Down Expand Up @@ -64,6 +66,13 @@ spec:
description: The AWS region to connect to
type: string
example: eu-west-1
useDefaultCredentialsProvider:
title: Default Credentials Provider
description: Set whether the Kinesis Firehose 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:aws2-kinesis"
- "camel:kamelet"
Expand All @@ -74,6 +83,7 @@ spec:
- to:
uri: "aws2-kinesis-firehose:{{streamName}}"
parameters:
accessKey: "{{accessKey}}"
secretKey: "{{secretKey}}"
accessKey: "{{?accessKey}}"
secretKey: "{{?secretKey}}"
region: "{{region}}"
useDefaultCredentialsProvider: "{{useDefaultCredentialsProvider}}"