UPD: updated variables and readme file

This commit is contained in:
xpk 2024-02-09 10:31:43 +08:00
parent a83c9575dc
commit 9d3b66b3a3
Signed by: xpk
GPG Key ID: CD4FF6793F09AB86
2 changed files with 30 additions and 16 deletions

View File

@ -6,7 +6,7 @@ This module performs the following tasks:
- Create subnets in every AZ
- Create IGW, NGW
- Create s3 and ddb endpoints which are free
-
## Requirements
No requirements.
@ -55,18 +55,18 @@ No requirements.
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| create-free-vpc-endpoints | variable "private-subnet-cidrs" {} variable "public-subnet-cidrs" {} | `bool` | `true` | no |
| create-nat-gateway | n/a | `bool` | `false` | no |
| enable-flow-log | n/a | `bool` | `true` | no |
| create-free-vpc-endpoints | Set true to deploy s3 and dynamodb endpoints, which are free | `bool` | `true` | no |
| create-nat-gateway | Set true to deploy NAT gateway | `bool` | `false` | no |
| enable-flow-log | Set true to deploy vpc flowlog | `bool` | `true` | no |
| log-group-class | Log group class for flowlog cloudwatch log group, which can be STANDARD or INFREQUENT\_ACCESS | `string` | `"STANDARD"` | no |
| num\_azs | By default, use 2 AZs for redundancy | `number` | `2` | no |
| private-subnet-cidrs | n/a | `list(any)` | n/a | yes |
| public-subnet-cidrs | n/a | `list(any)` | n/a | yes |
| private-subnet-cidrs | List of private subnet cidrs | `list(string)` | n/a | yes |
| public-subnet-cidrs | List of public subnet cidrs | `list(string)` | n/a | yes |
| resource-prefix | n/a | `any` | n/a | yes |
| secondary\_cidr\_blocks | Additional cidr blocks | `list(string)` | `[]` | no |
| vpc-cidr | VPC variables | `any` | n/a | yes |
| vpcflowlog-cwl-loggroup-key-arn | n/a | `any` | n/a | yes |
| vpcflowlog-retain-days | n/a | `number` | `90` | no |
| vpc-cidr | CIDR of VPC to be created | `string` | n/a | yes |
| vpcflowlog-cwl-loggroup-key-arn | CWL log group encryption key arn | `string` | n/a | yes |
| vpcflowlog-retain-days | Days to retain flowlog | `number` | `90` | no |
## Outputs
@ -85,4 +85,4 @@ No requirements.
---
## Authorship
This module was developed by xpk.
This module was developed by UPDATE_THIS.

View File

@ -1,35 +1,49 @@
variable "resource-prefix" {}
# VPC variables
variable "vpc-cidr" {}
variable "vpc-cidr" {
type = string
description = "CIDR of VPC to be created"
}
variable "private-subnet-cidrs" {
type = list(any)
description = "List of private subnet cidrs"
type = list(string)
}
variable "public-subnet-cidrs" {
type = list(any)
description = "List of public subnet cidrs"
type = list(string)
}
variable "create-nat-gateway" {
description = "Set true to deploy NAT gateway"
type = bool
default = false
}
variable "enable-flow-log" {
description = "Set true to deploy vpc flowlog"
type = bool
default = true
}
variable "vpcflowlog-retain-days" {
description = "Days to retain flowlog"
type = number
default = 90
}
variable "vpcflowlog-cwl-loggroup-key-arn" {}
# variable "private-subnet-cidrs" {}
# variable "public-subnet-cidrs" {}
variable "vpcflowlog-cwl-loggroup-key-arn" {
description = "CWL log group encryption key arn"
type = string
}
variable "create-free-vpc-endpoints" {
description = "Set true to deploy s3 and dynamodb endpoints, which are free"
type = bool
default = true
}
variable "secondary_cidr_blocks" {
type = list(string)
description = "Additional cidr blocks"