Skip to content

Commit 0b1c208

Browse files
authored
doc(redis): added documentation for redis cluster (#1257)
1 parent bcca1e0 commit 0b1c208

File tree

1 file changed

+74
-0
lines changed

1 file changed

+74
-0
lines changed

docs/resources/redis_cluster.md

+74
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
---
2+
page_title: "Scaleway: scaleway_redis_cluster"
3+
description: |-
4+
Manages Scaleway Redis Clusters.
5+
---
6+
7+
# scaleway_redis_cluster
8+
9+
Creates and manages Scaleway Redis Clusters.
10+
For more information, see [the documentation](https://developers.scaleway.com/en/products/redis/api).
11+
12+
## Examples
13+
14+
### Basic
15+
16+
```hcl
17+
resource "scaleway_redis_cluster" "main" {
18+
name = "test_redis_basic"
19+
version = "6.2.6"
20+
node_type = "MDB-BETA-M"
21+
user_name = "my_initial_user"
22+
password = "thiZ_is_v&ry_s3cret"
23+
tags = [ "test", "redis" ]
24+
cluster_size = 1
25+
tls_enabled = "true"
26+
}
27+
```
28+
29+
## Arguments Reference
30+
31+
The following arguments are supported:
32+
33+
- `version` - (Required) Redis's Cluster version (e.g. `6.2.6`).
34+
35+
~> **Important:** Updates to `version` will migrate the Redis Cluster to the desired `version`. Keep in mind that you cannot downgrade a Redis Cluster.
36+
37+
- `node_type` - (Required) The type of Redis Cluster you want to create (e.g. `MDB-BETA-M`).
38+
39+
~> **Important:** Updates to `node_type` will migrate the Redis Cluster to the desired `node_type`. Keep in mind that you cannot downgrade a Redis Cluster.
40+
41+
- `user_name` - (Required) Identifier for the first user of the Redis Cluster.
42+
43+
- `password` - (Required) Password for the first user of the Redis Cluster.
44+
45+
- `name` - (Optional) The name of the Redis Cluster.
46+
47+
- `tags` - (Optional) The tags associated with the Redis Cluster.
48+
49+
- `zone` - (Defaults to [provider](../index.md) `zone`) The [zone](../guides/regions_and_zones.md#zones) in which the Redis Cluster should be created.
50+
51+
- `cluster_size` - (Optional) The number of nodes in the Redis Cluster.
52+
53+
~> **Important:** You can set a bigger `cluster_size`, it will migrate the Redis Cluster, but keep in mind that you cannot downgrade a Redis Cluster so setting a smaller `cluster_size` will not have any effect.
54+
55+
- `tls_enabled` - (Defaults to false) Whether TLS is enabled or not.
56+
57+
- `project_id` - (Defaults to [provider](../index.md) `project_id`) The ID of the project the Redis Cluster is associated with.
58+
59+
## Attributes Reference
60+
61+
In addition to all arguments above, the following attributes are exported:
62+
63+
- `id` - The ID of the Database Instance.
64+
- `created_at` - The date and time of creation of the Redis Cluster.
65+
- `updated_at` - The date and time of the last update of the Redis Cluster.
66+
67+
68+
## Import
69+
70+
Redis Cluster can be imported using the `{zone}/{id}`, e.g.
71+
72+
```bash
73+
$ terraform import scaleway_redis_cluster.redis01 fr-par/11111111-1111-1111-1111-111111111111
74+
```

0 commit comments

Comments
 (0)