frostmoln_redis_instance (Resource)
Manages a managed Redis instance in the Frostmoln platform.
Example Usage
terraform
resource "frostmoln_redis_instance" "cache" {
name = "my-cache"
version = "7.2"
flavor_id = "cache.gp1.small"
vpc_id = frostmoln_vpc.main.id
subnet_id = frostmoln_subnet.private.id
persistence_mode = "rdb"
eviction_policy = "allkeys-lru"
# Scheduled backups require a persistence_mode other than "none".
backup_enabled = true
backup_schedule = "0 2 * * *"
backup_retention_days = 35
}Schema
Required
flavor_id(String) The flavor/size for the Redis instance (e.g. "cache.gp1.small", "cache.gp1.medium"). Changing this triggers an in-place flavor resize, which RESTARTS the instance (brief downtime) — unlike an online storage grow. Cannot be changed together with storage_gb in the same apply.name(String) The name of the Redis instance.subnet_id(String) The subnet ID where the Redis instance will be deployed.version(String) The Redis version (e.g. "7.2", "7.4").vpc_id(String) The VPC ID where the Redis instance will be deployed.
Optional
backup_enabled(Boolean) Whether automated backups are enabled. Requires a persistence_mode other than "none".backup_retention_days(Number) Number of days to retain backups. Minimum 35 (backups are immutably object-locked for 35 days); maximum 90. Defaults to 35 server-side.backup_schedule(String) Cron expression for the backup schedule. Defaults to "0 2 * * *".eviction_policy(String) The eviction policy for the Redis instance (e.g. "noeviction", "allkeys-lru"). Defaults to "noeviction".persistence_mode(String) The persistence mode for the Redis instance ("rdb", "aof", or "none"). Defaults to "rdb".storage_gb(Number) The storage size in gigabytes (defaults to 10 if unset). Can only be increased (grow-only); volumes cannot be shrunk.
Read-Only
admin_username(String) The admin username for the Redis instance.created_at(String) The timestamp when the instance was created.id(String) The unique identifier of the Redis instance.port(Number) The port number the Redis instance is listening on.private_ip(String) The private IP address of the Redis instance.status(String) The current status of the Redis instance.updated_at(String) The timestamp when the instance was last updated.