How do you restrict database access in Kubernetes? #104
-
I want to know what mechanisms there are to restrict access to a Database from a Kubernetes Pod. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
This comment has been hidden.
This comment has been hidden.
-
There are several ways to do this:
|
Beta Was this translation helpful? Give feedback.
There are several ways to do this:
If the database credentials are stored in AWS Secrets Manager, you can restrict which secrets the Pod has access to at the IAM role layer. That is, you setup an IAM policy to only allow the pod to access the secrets it needs and attach it to the IAM role corresponding to the service account.
If the database credentials are stored in Kubernetes Secrets, then you can manage the RBAC permissions on the service account attached to the Pod to restrict which secrets it has access to mount in.
We also support the following ways to restrict network access to the data store:
If you are using Fargate, you can control which subnets the pods will source it’s…