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

Assume role support for aws eks credentials #630

Conversation

alauddinulaganathan
Copy link
Contributor

@alauddinulaganathan alauddinulaganathan commented Mar 27, 2024

  1. Describe what this Pull Request does and why you think it is needed.
    We are using this kubeclient to perform API operations against the AWS EKS (kubernetes) clusters (i.e. the Kubernetes API Server). But we are not using access_key & secret_key directly as it is generally considered insecure. Hence we use - role based access control along with AWS STS to perform authentication (i.e. short lived temporary credentials). But the support for such Credentials Provider is not there in this Client (only supports - static Credentials & profile based static credentials).

I tried a small change to support the AssumeRoleCredentials Provider and it worked nicely. Hence I thought this would be a nice feature enhancement for this repo to users like me who want to use role based access with STS assumed role credentials.

  1. If this fixes an existing issue, please specify in Fixes #<id> format
    Not a bug fix. It is a feature enhancement.

@alauddinulaganathan
Copy link
Contributor Author

@miq-bot add-label enhancement
@miq-bot add-label aws
@miq-bot add-label eks
@miq-bot add-label aws_eks

README.md Outdated Show resolved Hide resolved
lib/kubeclient/aws_eks_credentials.rb Outdated Show resolved Hide resolved
@agrare agrare self-assigned this Apr 2, 2024
Copy link
Member

@agrare agrare left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, test failures look unrelated to this change I'll fix those in another PR

@agrare
Copy link
Member

agrare commented Apr 2, 2024

Test failures should be resolved by #631 and #632

@agrare agrare closed this Apr 2, 2024
@agrare agrare reopened this Apr 2, 2024
@agrare agrare merged commit 9f95df3 into ManageIQ:master Apr 2, 2024
26 checks passed
agrare added a commit to agrare/kubeclient that referenced this pull request Jun 18, 2024
…support_for_aws_eks_credentials

Assume role support for aws eks credentials

(cherry picked from commit 9f95df3)
agrare added a commit to agrare/kubeclient that referenced this pull request Jun 18, 2024
Added
- Add test coverage for Ruby 3.2 (ManageIQ#615)
- Allow a region when getting a signer for Aws::Sts (ManageIQ#507)
- Update the AWS STS endpoint to be regional as the method is now regional (ManageIQ#528)
- Assume role support for aws eks credentials (ManageIQ#630)

Fixed
- [v4.y] Regenerated expired test TLS certs by running `test/config/update_certs_k0s.rb`.
- [v4.y] Regenerated expired test TLS certs (ManageIQ#611)
- Regenerated expired test TLS certs (ManageIQ#632)

Changed
- Update actions/checkout (ManageIQ#590)
- chore(deps): update actions/checkout action to v4 (ManageIQ#619)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants