Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions config/elasticache/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,14 @@ func Configure(p *config.Provider) { //nolint:gocyclo
r.References["parameter_group_name"] = config.Reference{
TerraformName: "aws_elasticache_parameter_group",
}
r.Sensitive.AdditionalConnectionDetailsFn = func(attr map[string]any) (map[string][]byte, error) {
conn := map[string][]byte{}
// This only works for memcached clusters
if a, ok := attr["cluster_address"].(string); ok {
conn["cluster_address"] = []byte(a)
}
return conn, nil
}
// log_delivery_configuration.destination can point to either
// a CloudWatch Logs LogGroup or Kinesis Data Firehose resource.
delete(r.References, "log_delivery_configuration.destination")
Expand Down
3 changes: 3 additions & 0 deletions examples/elasticache/v1beta1/cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ spec:
subnetGroupNameSelector:
matchLabels:
testing.upbound.io/example-name: example
writeConnectionSecretToRef:
name: sample-cluster
namespace: default

---

Expand Down