Required provider_config¶
AWS requires four fields, the largest required set after Azure.
| Field | Flag | Example |
|---|---|---|
account_id |
--account-id |
<aws-account-id> |
region |
--region |
<region> |
cluster_oidc_issuer |
--cluster-oidc-issuer |
https://oidc.eks.<region>.amazonaws.com/id/<cluster-oidc-id> |
cluster_oidc_provider_arn |
--cluster-oidc-provider-arn |
arn:aws:iam::<aws-account-id>:oidc-provider/oidc.eks.<region>.amazonaws.com/id/<cluster-oidc-id> |
The last two are the ones GCP and Azure do not ask for in this form. See Cluster OIDC values.
As flags¶
xratu dataplane install prepare acme edge-eu dp-eu-west1 \
--provider aws \
--dp-count 2 \
--artifact-registry <aws-account-id>.dkr.ecr.<region>.amazonaws.com/<repository> \
--artifact-bucket s3://<bucket>/<prefix> \
--account-id <aws-account-id> \
--region <region> \
--cluster-oidc-issuer https://oidc.eks.<region>.amazonaws.com/id/<cluster-oidc-id> \
--cluster-oidc-provider-arn arn:aws:iam::<aws-account-id>:oidc-provider/oidc.eks.<region>.amazonaws.com/id/<cluster-oidc-id>
As a spec¶
provider: aws
provider_config:
account_id: '<aws-account-id>'
region: <region>
cluster_oidc_issuer: https://oidc.eks.<region>.amazonaws.com/id/<cluster-oidc-id>
cluster_oidc_provider_arn: arn:aws:iam::<aws-account-id>:oidc-provider/oidc.eks.<region>.amazonaws.com/id/<cluster-oidc-id>
aws_sts_endpoint: ''
aws_ecr_api_endpoint: ''
Quote account_id in YAML so a numeric account is carried as a string.
The two endpoint fields at the bottom are the private-network override points. See Air-gapped deployment.
What each is used for¶
account_id appears in the role ARNs that go into the service account
annotations, and in the S3 resource ARNs.
region configures the Terraform AWS provider and should match the region
in your ECR registry path.
cluster_oidc_provider_arn is the federated principal in each role's trust
policy.
cluster_oidc_issuer is the condition variable in that trust policy, which
restricts the role to one Kubernetes service account.
Missing fields fail at prepare¶
provider_config.cluster_oidc_issuer is required for aws
provider_config.cluster_oidc_provider_arn is required for aws
Each is checked separately, so the failure names the missing one.
Finding the two OIDC values¶
aws eks describe-cluster --name <cluster-name> --region <region> \
--query "cluster.identity.oidc.issuer" --output text
See Cluster OIDC values for what to do when the provider does not exist yet.