简体   繁体   English

如何使用 IAM 角色而不是访问密钥和秘密密钥将 Amazon S3 存储桶访问到 Kube.netes pod?

[英]How to access Amazon S3 bucket to the Kubernetes pods using IAM roles instead of Access key & secret keys?

I am trying to mount S3 bucket using s3fs-fuse to the Kube.netes pod.我正在尝试使用 s3fs-fuse 将 S3 存储桶挂载到 Kube.netes pod。 My S3 bucket is protected by IAM roles and i dont have Access Keys and Secret Keys to access S3 bucket.我的 S3 存储桶受 IAM 角色保护,我没有访问密钥和秘密密钥来访问 S3 存储桶。 I know how to access a S3bucket from the Kube.netes pod using Access & Secrets Keys, but how do we access S3 bucket using IAM roles?我知道如何使用访问和秘密密钥从 Kube.netes pod 访问 S3bucket,但我们如何使用 IAM 角色访问 S3 存储桶?

Does anyone has suggestion on doing this?有人对此有建议吗?

You use the IRSA system, attaching an IAM role to a Kube.netes service account and then attaching that K8s SA to your pod.您使用 IRSA 系统,将 IAM 角色附加到 Kube.netes 服务帐户,然后将该 K8s SA 附加到您的 pod。 See https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html for a starting point.请参阅https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html作为起点。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM