-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Dmitry Kropachev
committed
Apr 20, 2024
1 parent
b4e63e1
commit 31dea58
Showing
4 changed files
with
113 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
--- | ||
page_title: "scylladbcloud_cluster_connection Resource - terraform-provider-scylladbcloud" | ||
subcategory: "" | ||
description: |- | ||
--- | ||
|
||
# scylladbcloud_cluster_connection (Resource) | ||
|
||
|
||
|
||
## Example of AWS Transit Gateway VPC Attachment Cluster Connection | ||
|
||
```terraform | ||
# Create AWS TGW VPC Attachment Connection for the specified cluster. | ||
resource "scylladbcloud_cluster_connection" "aws_tgw" { | ||
cluster_id = 1337 | ||
name = "aws-tgw-test" | ||
cidrlist = ["10.201.0.0/16"] | ||
type = "AWS_TGW_ATTACHMENT" | ||
datacenter = "AWS_US_EAST_1" | ||
data = { | ||
tgwid = "tgw-08461afa1119f390a" | ||
ramarn = "arn:aws:ram:us-east-1:043400831220:resource-share/be3b0395-1782-47cb-9ae4-6d3517c6a721" | ||
} | ||
} | ||
output "scylladbcloud_cluster_connection_id" { | ||
value = scylladbcloud_cluster_connection.aws_tgw.id | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `cidrlist` (List of String) List of CIDRs to route to the cluster connection | ||
- `cluster_id` (Number) Cluster ID | ||
- `data` (Map of String) Connection Data | ||
- `datacenter` (String) Cluster datacenter name | ||
- `type` (String) Connection Type | ||
|
||
### Optional | ||
|
||
- `name` (String) Cluster Connection Name | ||
- `status` (String) Connection Status | ||
- `timeouts` (Block, Optional) (see [below for nested schema](#nestedblock--timeouts)) | ||
|
||
### Read-Only | ||
|
||
- `external_id` (String) ID of the cloud resource that represents connection | ||
- `id` (String) Cluster connection ID | ||
|
||
<a id="nestedblock--timeouts"></a> | ||
### Nested Schema for `timeouts` | ||
|
||
Optional: | ||
|
||
- `create` (String) | ||
- `delete` (String) | ||
- `update` (String) | ||
|
||
## Import | ||
|
||
Import is supported using the following syntax: | ||
|
||
```shell | ||
# An cluster connection can be imported by specifying the numeric identifier. | ||
terraform import scylladbcloud_cluster_connection.example 123 | ||
``` |
17 changes: 17 additions & 0 deletions
17
examples/resources/scylladbcloud_cluster_connection/aws-tgw-vpc-attachment.tf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Create AWS TGW VPC Attachment Connection for the specified cluster. | ||
|
||
resource "scylladbcloud_cluster_connection" "aws_tgw" { | ||
cluster_id = 1337 | ||
name = "aws-tgw-test" | ||
cidrlist = ["10.201.0.0/16"] | ||
type = "AWS_TGW_ATTACHMENT" | ||
datacenter = "AWS_US_EAST_1" | ||
data = { | ||
tgwid = "tgw-08461afa1119f390a" | ||
ramarn = "arn:aws:ram:us-east-1:043400831220:resource-share/be3b0395-1782-47cb-9ae4-6d3517c6a721" | ||
} | ||
} | ||
|
||
output "scylladbcloud_cluster_connection_id" { | ||
value = scylladbcloud_cluster_connection.aws_tgw.id | ||
} |
2 changes: 2 additions & 0 deletions
2
examples/resources/scylladbcloud_cluster_connection/import.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# An cluster connection can be imported by specifying the numeric identifier. | ||
terraform import scylladbcloud_cluster_connection.example 123 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
page_title: "{{.Name}} {{.Type}} - {{.ProviderName}}" | ||
subcategory: "" | ||
description: |- | ||
{{ .Description | plainmarkdown | trimspace | prefixlines " " }} | ||
--- | ||
|
||
# {{.Name}} ({{.Type}}) | ||
|
||
{{ .Description | trimspace }} | ||
|
||
## Example of AWS Transit Gateway VPC Attachment Cluster Connection | ||
|
||
{{ tffile (printf "examples/resources/%s/aws-tgw-vpc-attachment.tf" .Name)}} | ||
|
||
{{ .SchemaMarkdown | trimspace }} | ||
|
||
## Import | ||
|
||
Import is supported using the following syntax: | ||
|
||
{{ codefile "shell" (printf "examples/resources/%s/import.sh" .Name)}} |