frostmoln_valkey_instance (Resource)
Manages a managed Valkey instance in the Frostmoln platform.
Example Usage
terraform
resource "frostmoln_valkey_instance" "cache" {
name = "app-cache"
version = "8.1"
flavor_id = "cache.gp1.small"
vpc_id = frostmoln_vpc.main.id
subnet_id = frostmoln_subnet.private.id
persistence_mode = "rdb"
eviction_policy = "allkeys-lru"
}
output "valkey_endpoint" {
value = "${frostmoln_valkey_instance.cache.private_ip}:${frostmoln_valkey_instance.cache.port}"
}Schema
Required
flavor_id(String) The flavor/size for the Valkey 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 Valkey instance.subnet_id(String) The subnet ID where the Valkey instance will be deployed.version(String) The Valkey version (e.g. "8.1").vpc_id(String) The VPC ID where the Valkey instance will be deployed.
Optional
eviction_policy(String) The eviction policy for the Valkey instance (e.g. "noeviction", "allkeys-lru"). Defaults to "noeviction".persistence_mode(String) The persistence mode for the Valkey instance ("rdb", "aof", "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 Valkey instance.created_at(String) The timestamp when the instance was created.id(String) The unique identifier of the Valkey instance.port(Number) The port number the Valkey instance is listening on.private_ip(String) The private IP address of the Valkey instance.status(String) The current status of the Valkey instance.updated_at(String) The timestamp when the instance was last updated.