To access the Kubernetes cluster, you must first obtain the credentials from the AWS Console.
- Go to the AWS Console and navigate to the AWS Secret Manager.
- Under "Secret Value," click on "Retrieve Secret Value" to securely access the Kubernetes credentials.
Next, create a new cluster using the kubectl utility:
- Open your terminal or command prompt.
- Ensure that you have the kubectl utility installed and properly configured to access your cluster.
- Use the following command as a template, replacing the placeholder values with your actual secret information:
To log in to a specific pod deployed in the Kubernetes cluster, follow these steps in your terminal:
To interact with an application that is running within a Kubernetes cluster from your local environment, follow these steps in your terminal:
By default, the EKS cluster is set up with minimal permissions to AWS resources, prioritizing security.
However, many times the applications running within the cluster require access to specific AWS resources such as SES, SQS, SNS, and Cognito to ensure smooth operation.
To accomplish this, follow these steps to extend the default permissions:
- Access the AWS Console
- Navigate to the IAM Service
- In the IAM dashboard, search for the "NodeInstanceRole" role linked to your EKS cluster
- Within the role details, locate the "Add Permissions" dropdown menu
- From the dropdown, choose "Attach Policies"
- Browse and choose the policy that provides the required permissions for the AWS resources your apps need to access
- After selecting the desired policy, click the "Add permissions" button to apply the changes.
By following these steps, you can seamlessly grant your applications the necessary access to AWS resources while maintaining the overall security of your EKS cluster.