A Kubernetes operator that syncs configuration from external sources (like AWS SSM Parameter Store) into Kubernetes ConfigMaps and Secrets, keeping them automatically up to date.
┌──────────────────┐ ┌───────────────┐ ┌──────────────────┐
│ AWS SSM │ │ config-sync │ │ Kubernetes │
│ Parameter Store │ ──────► │ controller │ ──────► │ ConfigMap or │
│ │ fetch │ │ create │ Secret │
└──────────────────┘ └───────────────┘ /update└──────────────────┘
▲
│ watches
┌─────┴──────┐
│ ConfigSync │
│ Custom │
│ Resource │
└────────────┘
You define a ConfigSync custom resource that specifies:
- Source: where to read the config (e.g., AWS SSM parameter name and region)
- Target: where to write it (a Kubernetes ConfigMap or Secret)
- RefreshInterval: how often to re-sync (e.g.,
5m,1h)
The controller continuously fetches the value and keeps the target resource in sync.
- Go 1.25+
- A Kubernetes cluster (v1.30+)
- kubectl configured to access the cluster
- AWS credentials with
ssm:GetParameterpermission
make installmake runapiVersion: sre.sre.dev/v1
kind: ConfigSync
metadata:
name: app-config
spec:
source:
type: ssm
name: /staging/app/config
region: us-east-1
target:
type: configmap
name: app-config
refreshInterval: "5m"kubectl apply -f config/samples/sre_v1_configsync.yamlkubectl get configsync
kubectl get configmap app-config -o yaml| Field | Description | Example |
|---|---|---|
type |
Source type | ssm |
name |
Parameter name in the source | /staging/app/config |
region |
AWS region | us-east-1 |
| Field | Description | Example |
|---|---|---|
type |
Kubernetes resource type | configmap or secret |
name |
Name of the ConfigMap or Secret to create | app-config |
| Field | Description | Default |
|---|---|---|
refreshInterval |
How often to re-sync (Go duration) | 5m |
The operator handles two formats from SSM:
- JSON string:
{"db_host": "rds.aws.com", "db_port": "5432"}— each key-value pair becomes a separate entry in the ConfigMap/Secret - Plain string:
my-value— stored as a single entry using a sanitized version of the parameter name as the key
make docker-build docker-push IMG=<your-registry>/config-sync:latestmake deploy IMG=<your-registry>/config-sync:latestmake undeployThe controller needs the following IAM permissions:
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "ssm:GetParameter",
"Resource": "arn:aws:ssm:*:*:parameter/*"
}
]
}For EKS, use IAM Roles for Service Accounts (IRSA) to grant the controller access.
make manifests # Regenerate CRD manifests after API changes
make generate # Regenerate deep copy methods
make test # Run tests
make run # Run locally against the configured clusterSee CONTRIBUTING.md for more details.
Apache License 2.0 — see LICENSE for details.