Skip to content

Commit

Permalink
fix: Update redis TTL (#20)
Browse files Browse the repository at this point in the history
* update redis ttl

* format
  • Loading branch information
elainaRenee authored May 11, 2022
1 parent da32771 commit f56cfff
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ module "redis" {

locals {
redis_certificate = var.create_redis ? module.redis.0.ca_cert : null
redis_connection_string = var.create_redis ? "redis://:${module.redis.0.auth_string}@${module.redis.0.connection_string}?tls=true&ttlInSeconds=60&caCertPath=/etc/ssl/certs/server_ca.pem" : null
redis_connection_string = var.create_redis ? "redis://:${module.redis.0.auth_string}@${module.redis.0.connection_string}?tls=true&ttlInSeconds=604800&caCertPath=/etc/ssl/certs/server_ca.pem" : null
bucket = local.create_bucket ? module.storage.0.bucket_name : var.bucket_name
bucket_queue = var.use_internal_queue ? "internal://" : "pubsub:/${module.storage.0.bucket_queue_name}"
}
Expand Down
4 changes: 2 additions & 2 deletions modules/redis/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ output "connection_string" {
}

output "ca_cert" {
value = "${google_redis_instance.default.server_ca_certs[0].cert}"
value = google_redis_instance.default.server_ca_certs[0].cert
}

output "auth_string" {
value = "${google_redis_instance.default.auth_string}"
value = google_redis_instance.default.auth_string
}

1 change: 1 addition & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ variable "create_redis" {
##########################################
# Most users will not need these settings. They are ment for users who want a
# bucket in a different account.

variable "bucket_name" {
type = string
description = "Use an existing bucket."
Expand Down

0 comments on commit f56cfff

Please sign in to comment.