Skip to content

Commit 0890a2f

Browse files
committed
update readme files with examples and descriptions
1 parent 2a777e4 commit 0890a2f

File tree

2 files changed

+141
-0
lines changed

2 files changed

+141
-0
lines changed

examples/dsql/README.md

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
# Aurora DSQL Cluster Example
2+
3+
Configuration in this directory creates multi-region peered Aurora DSQL clusters and a single region Aurora DSQL cluster.
4+
5+
## Usage
6+
7+
To run this example you need to execute:
8+
9+
```bash
10+
$ terraform init
11+
$ terraform plan
12+
$ terraform apply
13+
```
14+
15+
Note that this example may create resources which cost money. Run `terraform destroy` when you don't need these resources.
16+
17+
<!-- BEGIN_TF_DOCS -->
18+
## Requirements
19+
20+
| Name | Version |
21+
|------|---------|
22+
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.0 |
23+
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 5.100 |
24+
25+
## Providers
26+
27+
No providers.
28+
29+
## Modules
30+
31+
| Name | Source | Version |
32+
|------|--------|---------|
33+
| <a name="module_dsql_cluster_1"></a> [dsql\_cluster\_1](#module\_dsql\_cluster\_1) | ../../modules/dsql | n/a |
34+
| <a name="module_dsql_cluster_2"></a> [dsql\_cluster\_2](#module\_dsql\_cluster\_2) | ../../modules/dsql | n/a |
35+
| <a name="module_dsql_single_region"></a> [dsql\_single\_region](#module\_dsql\_single\_region) | ../../modules/dsql | n/a |
36+
37+
## Resources
38+
39+
No resources.
40+
41+
## Inputs
42+
43+
No inputs.
44+
45+
## Outputs
46+
47+
| Name | Description |
48+
|------|-------------|
49+
| <a name="output_dsql_cluster_1_arn"></a> [dsql\_cluster\_1\_arn](#output\_dsql\_cluster\_1\_arn) | ARN of the cluster |
50+
| <a name="output_dsql_cluster_1_encryption_details"></a> [dsql\_cluster\_1\_encryption\_details](#output\_dsql\_cluster\_1\_encryption\_details) | Encryption configuration details for the DSQL cluster |
51+
| <a name="output_dsql_cluster_1_identifier"></a> [dsql\_cluster\_1\_identifier](#output\_dsql\_cluster\_1\_identifier) | Cluster identifier |
52+
| <a name="output_dsql_cluster_1_multi_region_properties"></a> [dsql\_cluster\_1\_multi\_region\_properties](#output\_dsql\_cluster\_1\_multi\_region\_properties) | Multi-region properties of the DSQL cluster |
53+
| <a name="output_dsql_cluster_1_vpc_endpoint_service_name"></a> [dsql\_cluster\_1\_vpc\_endpoint\_service\_name](#output\_dsql\_cluster\_1\_vpc\_endpoint\_service\_name) | The DSQL cluster's VPC endpoint service name |
54+
| <a name="output_dsql_cluster_2_arn"></a> [dsql\_cluster\_2\_arn](#output\_dsql\_cluster\_2\_arn) | ARN of the cluster |
55+
| <a name="output_dsql_cluster_2_encryption_details"></a> [dsql\_cluster\_2\_encryption\_details](#output\_dsql\_cluster\_2\_encryption\_details) | Encryption configuration details for the DSQL cluster |
56+
| <a name="output_dsql_cluster_2_identifier"></a> [dsql\_cluster\_2\_identifier](#output\_dsql\_cluster\_2\_identifier) | Cluster identifier |
57+
| <a name="output_dsql_cluster_2_multi_region_properties"></a> [dsql\_cluster\_2\_multi\_region\_properties](#output\_dsql\_cluster\_2\_multi\_region\_properties) | Multi-region properties of the DSQL cluster |
58+
| <a name="output_dsql_cluster_2_vpc_endpoint_service_name"></a> [dsql\_cluster\_2\_vpc\_endpoint\_service\_name](#output\_dsql\_cluster\_2\_vpc\_endpoint\_service\_name) | The DSQL cluster's VPC endpoint service name |
59+
<!-- END_TF_DOCS -->

modules/dsql/README.md

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
# DSQL Cluster
2+
3+
Terraform sub-module which creates DSQL cluster and peering resources.
4+
5+
## Usage
6+
7+
See [DSQL](https://github.com/terraform-aws-modules/terraform-aws-rds-aurora/tree/master/examples/dsql) directory for working examples to reference:
8+
9+
```hcl
10+
module "dsql_cluster_1" {
11+
source = "../../modules/dsql"
12+
13+
witness_region = "us-west-2"
14+
create_cluster_peering = true
15+
clusters = [module.dsql_cluster_2.arn]
16+
17+
tags = { Name = "dsql-1" }
18+
}
19+
20+
module "dsql_cluster_2" {
21+
source = "../../modules/dsql"
22+
23+
witness_region = "us-west-2"
24+
create_cluster_peering = true
25+
clusters = [module.dsql_cluster_1.arn]
26+
27+
tags = { Name = "dsql-2" }
28+
29+
providers = {
30+
aws = aws.region2
31+
}
32+
}
33+
```
34+
35+
<!-- BEGIN_TF_DOCS -->
36+
## Requirements
37+
38+
| Name | Version |
39+
|------|---------|
40+
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.0 |
41+
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 5.100 |
42+
43+
## Providers
44+
45+
| Name | Version |
46+
|------|---------|
47+
| <a name="provider_aws"></a> [aws](#provider\_aws) | >= 5.100 |
48+
49+
## Modules
50+
51+
No modules.
52+
53+
## Resources
54+
55+
| Name | Type |
56+
|------|------|
57+
| [aws_dsql_cluster.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/dsql_cluster) | resource |
58+
| [aws_dsql_cluster_peering.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/dsql_cluster_peering) | resource |
59+
60+
## Inputs
61+
62+
| Name | Description | Type | Default | Required |
63+
|------|-------------|------|---------|:--------:|
64+
| <a name="input_clusters"></a> [clusters](#input\_clusters) | List of DSQL Cluster ARNs to be peered to this cluster | `list(string)` | `null` | no |
65+
| <a name="input_create"></a> [create](#input\_create) | Whether cluster should be created (affects all resources) | `bool` | `true` | no |
66+
| <a name="input_create_cluster_peering"></a> [create\_cluster\_peering](#input\_create\_cluster\_peering) | Whether to create cluster peering | `bool` | `false` | no |
67+
| <a name="input_deletion_protection_enabled"></a> [deletion\_protection\_enabled](#input\_deletion\_protection\_enabled) | Whether deletion protection is enabled in this cluster | `bool` | `null` | no |
68+
| <a name="input_kms_encryption_key"></a> [kms\_encryption\_key](#input\_kms\_encryption\_key) | The ARN of the AWS KMS key that encrypts data in the DSQL Cluster, or `AWS_OWNED_KMS_KEY` | `string` | `null` | no |
69+
| <a name="input_tags"></a> [tags](#input\_tags) | A map of tags to be associated with the AWS DSQL Cluster resource | `map(string)` | `{}` | no |
70+
| <a name="input_timeouts"></a> [timeouts](#input\_timeouts) | Create timeout configuration for the cluster | `any` | `{}` | no |
71+
| <a name="input_witness_region"></a> [witness\_region](#input\_witness\_region) | Witness region for the multi-region clusters. Setting this makes this cluster a multi-region cluster. Changing it recreates the cluster | `string` | `null` | no |
72+
73+
## Outputs
74+
75+
| Name | Description |
76+
|------|-------------|
77+
| <a name="output_arn"></a> [arn](#output\_arn) | ARN of the cluster |
78+
| <a name="output_encryption_details"></a> [encryption\_details](#output\_encryption\_details) | Encryption configuration details for the DSQL cluster |
79+
| <a name="output_identifier"></a> [identifier](#output\_identifier) | Cluster identifier |
80+
| <a name="output_multi_region_properties"></a> [multi\_region\_properties](#output\_multi\_region\_properties) | Multi-region properties of the DSQL cluster |
81+
| <a name="output_vpc_endpoint_service_name"></a> [vpc\_endpoint\_service\_name](#output\_vpc\_endpoint\_service\_name) | The DSQL cluster's VPC endpoint service name |
82+
<!-- END_TF_DOCS -->

0 commit comments

Comments
 (0)