Multi-Region
ACK controllers can manage resources across multiple AWS regions using a single controller deployment.
Region Precedence​
The controller determines the AWS region for a resource in this order:
- Resource annotation -
services.k8s.aws/regionon the resource itself - Namespace annotation -
services.k8s.aws/default-regionon the namespace - Controller flag -
--aws-regionflag (configurable via Helm chartaws.regionvalue)
The first match wins.
Configuration Options​
Resource-Level Region​
Override the region for a specific resource using the services.k8s.aws/region annotation:
apiVersion: dynamodb.services.k8s.aws/v1alpha1
kind: Table
metadata:
name: users-east
annotations:
services.k8s.aws/region: us-east-1
spec:
tableName: users-east
billingMode: PAY_PER_REQUEST
attributeDefinitions:
- attributeName: id
attributeType: S
keySchema:
- attributeName: id
keyType: HASH
This creates the table in us-east-1 regardless of the controller's default region.
Namespace-Level Region​
Set a default region for all resources in a namespace using the services.k8s.aws/default-region annotation:
apiVersion: v1
kind: Namespace
metadata:
name: production
annotations:
services.k8s.aws/default-region: us-east-1
Or for existing namespaces:
kubectl annotate namespace production services.k8s.aws/default-region=us-east-1
Now all resources in the production namespace default to us-east-1:
apiVersion: dynamodb.services.k8s.aws/v1alpha1
kind: Table
metadata:
name: orders
namespace: production
spec:
tableName: orders
billingMode: PAY_PER_REQUEST
attributeDefinitions:
- attributeName: orderID
attributeType: S
keySchema:
- attributeName: orderID
keyType: HASH
Next Steps​
- Advanced IAM roles - Use different IAM roles for different regions
- Create resources - Learn about resource creation