outputs.tf
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
output "redis_id" {
  description = "Redis replication group ID (null for Memcached)"
  value       = length(aws_elasticache_replication_group.this) > 0 ? aws_elasticache_replication_group.this["redis"].id : null
}

output "redis_arn" {
  description = "Redis replication group ARN"
  value       = length(aws_elasticache_replication_group.this) > 0 ? aws_elasticache_replication_group.this["redis"].arn : null
}

output "redis_primary_endpoint" {
  description = "Redis primary endpoint address"
  value       = length(aws_elasticache_replication_group.this) > 0 ? aws_elasticache_replication_group.this["redis"].primary_endpoint_address : null
}

output "redis_reader_endpoint" {
  description = "Redis reader endpoint address"
  value       = length(aws_elasticache_replication_group.this) > 0 ? aws_elasticache_replication_group.this["redis"].reader_endpoint_address : null
}

output "memcached_id" {
  description = "Memcached cluster ID (null for Redis)"
  value       = length(aws_elasticache_cluster.memcached) > 0 ? aws_elasticache_cluster.memcached["memcached"].id : null
}

output "memcached_configuration_endpoint" {
  description = "Memcached configuration endpoint"
  value       = length(aws_elasticache_cluster.memcached) > 0 ? aws_elasticache_cluster.memcached["memcached"].configuration_endpoint : null
}