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

Add Gradle dependency software.amazon.awssdk:sts #219

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

clupo
Copy link

@clupo clupo commented Feb 11, 2025

The AWS STS dependency is required to support the IRSA method of authentication when running in Kubernetes

Authentication with IRSA is the recommended way to access AWS resources

Example error from the connector if this package is not installed when attempting to access resources via an AWS service account:

WARN s.a.a.a.c.i.WebIdentityCredentialsUtils - To use web identity tokens, the 'sts' service module must be on the class path. Exception in thread "main" software.amazon.awssdk.core.exception.SdkClientException: Unable to load credentials from any of the providers in the chain AwsCredentialsProviderChain

When we deployed the connector to our environment with this added dependency the connector started up healthy and functioned as expected

Reference docs:
"Use IRSA with the AWS SDK" https://docs.aws.amazon.com/en_ca/eks/latest/userguide/iam-roles-for-service-accounts-minimum-sdk.html
"IRSA Overview" https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html

The AWS STS dependency is required to support the IRSA method of authentication when running in Kubernetes

Authentication with IRSA is the recommended way to access AWS resources

Example error from the connector if this package is not installed when attempting to access resources via an AWS service account:
WARN s.a.a.a.c.i.WebIdentityCredentialsUtils - To use web identity tokens, the 'sts' service module must be on the class path.
Exception in thread "main" software.amazon.awssdk.core.exception.SdkClientException: Unable to load credentials from any of the providers in the chain AwsCredentialsProviderChain

"IRSA Overview" https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html
"Use IRSA with the AWS SDK" https://docs.aws.amazon.com/en_ca/eks/latest/userguide/iam-roles-for-service-accounts-minimum-sdk.html

https://centeredge.atlassian.net/browse/DO-4758
@dnault
Copy link
Contributor

dnault commented Feb 11, 2025

Thank you very much!

Tracking as CBES-327. We'll aim to get this into this month's release.

Gerrit is our "source of truth" repository. Because this is such a minor change, I will just copy it over -- no need to sign a CLA.

We will credit you in the release notes by your GitHub profile link, unless you have a different preference.

Thanks again.

ns-codereview pushed a commit that referenced this pull request Feb 15, 2025
Modifications
-------------
Add dependency on `software.amazon.awssdk:sts`

Credits
-------
Thank you to https://github.com/clupo
#219

Change-Id: Icc860d573e763126593991ddc5b3050bb2dbef33
Reviewed-on: https://review.couchbase.org/c/couchbase-elasticsearch-connector/+/223226
Tested-by: Build Bot <[email protected]>
Reviewed-by: Michael Reiche <[email protected]>
@dnault
Copy link
Contributor

dnault commented Feb 24, 2025

We're running out of days in February, so "this month's" release will more likely be in March.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants