Set up a Kubernetes service account for ingestion separation resources.
Create and configure a Kubernetes service account with the minimum required permissions for ingestion and indexing resources to perform SQS and S3 operations. With this service account, Splunk uses the correct credentials to perform its tasks.
- Create a service account with the required IAM policies using eksctl.
The following example configures the ingestor-sa service account for the cluster in region us-west-2 with AmazonS3FullAccess and AmazonSQSFullAccess access policies:
eksctl create iamserviceaccount \
--name ingestor-sa \
--cluster ind-ing-sep-demo \
--region us-west-2 \
--attach-policy-arn arn:aws:iam::aws:policy/AmazonS3FullAccess \
--attach-policy-arn arn:aws:iam::aws:policy/AmazonSQSFullAccess \
--approve \
--override-existing-serviceaccounts
- Verify that the service account exists.
kubectl describe sa ingestor-sa
Expected output:
Name: ingestor-sa
Namespace: default
Labels: app.kubernetes.io/managed-by=eksctl
Annotations: eks.amazonaws.com/role-arn: arn:aws:iam::111111111111:role/eksctl-ind-ing-sep-demo-addon-iamserviceac-Role1-123456789123
Image pull secrets: <none>
Mountable secrets: <none>
Tokens: <none>
Events: <none>
- Verify the IAM role and attached policies.
aws iam get-role --role-name eksctl-ind-ing-sep-demo-addon-iamserviceac-Role1-123456789123
aws iam list-attached-role-policies --role-name eksctl-cluster-name-addon-iamserviceac-Role1-123456789123
Expected output shows AmazonSQSFullAccess and AmazonS3FullAccess policies attached.