Skip to content

Commit f562dab

Browse files
committed
Added a flaf to create virtual private gateway
1 parent d1c113f commit f562dab

File tree

6 files changed

+10
-11
lines changed

6 files changed

+10
-11
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,7 @@ module "this" {
100100
| <a name="input_client_vpn_subnet_ids"></a> [client\_vpn\_subnet\_ids](#input\_client\_vpn\_subnet\_ids) | The ID of the subnets to associate with the Client VPN endpoint. | `list(string)` | n/a | yes |
101101
| <a name="input_client_vpn_target_network_cidr"></a> [client\_vpn\_target\_network\_cidr](#input\_client\_vpn\_target\_network\_cidr) | The IPv4 address range, in CIDR notation, of the network to which the authorization rule applies. | `string` | n/a | yes |
102102
| <a name="input_create_self_signed_server_cert"></a> [create\_self\_signed\_server\_cert](#input\_create\_self\_signed\_server\_cert) | Create a self signed certificate to use for the VPN server. | `bool` | `true` | no |
103+
| <a name="input_create_vpn_gateway"></a> [create\_vpn\_gateway](#input\_create\_vpn\_gateway) | Whether to create VPN Gateway, as for a VPC only one Gateway is allowed | `bool` | `true` | no |
103104
| <a name="input_dns_servers"></a> [dns\_servers](#input\_dns\_servers) | The list of dns server ip address | `list(string)` | <pre>[<br> "1.1.1.1",<br> "1.0.0.1"<br>]</pre> | no |
104105
| <a name="input_iam_saml_provider_enabled"></a> [iam\_saml\_provider\_enabled](#input\_iam\_saml\_provider\_enabled) | Enable the SAML provider for SSO login to Client VPN. If enabled, `var.iam_saml_provider_name` and `var.saml_metadata_document_content` must be set. | `bool` | `false` | no |
105106
| <a name="input_iam_saml_provider_name"></a> [iam\_saml\_provider\_name](#input\_iam\_saml\_provider\_name) | The name of the IAM SAML Provider | `string` | `null` | no |

docs/module-usage-guide/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
This document provides guidelines and instructions for users looking to implement Terraform ARC module for managing a AWS Client VPN.
88

9-
#### What is AWS Client VPN ?
9+
#### What is AWS Client VPN ?
1010
AWS Client VPN is a managed remote access VPN solution used by your remote workforce to securely access resources within both AWS and your on-premises network. Fully elastic, it automatically scales up, or down, based on demand.
1111

1212
### Module Overview
@@ -51,7 +51,7 @@ Integrate the module with your existing Terraform mono repo configuration, follo
5151

5252
### Required AWS Permissions
5353

54-
Ensure that the AWS credentials used to execute Terraform have the necessary permissions to create
54+
Ensure that the AWS credentials used to execute Terraform have the necessary permissions to create
5555
- Client VPN Endpoint
5656
- Virtual Private Gateway
5757

example/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@
1818

1919
| Name | Source | Version |
2020
|------|--------|---------|
21-
| <a name="module_self_signed_cert_ca"></a> [self\_signed\_cert\_ca](#module\_self\_signed\_cert\_ca) | git::https://github.com/cloudposse/terraform-aws-ssm-tls-self-signed-cert.git | 1.3.0 |
21+
| <a name="module_self_signed_cert_ca"></a> [self\_signed\_cert\_ca](#module\_self\_signed\_cert\_ca) | git::https://github.com/cloudposse/terraform-aws-ssm-tls- self-signed-cert.git | 1.3.0 |
2222
| <a name="module_self_signed_cert_root"></a> [self\_signed\_cert\_root](#module\_self\_signed\_cert\_root) | git::https://github.com/cloudposse/terraform-aws-ssm-tls-self-signed-cert.git | 1.3.0 |
2323
| <a name="module_tags"></a> [tags](#module\_tags) | sourcefuse/arc-tags/aws | 1.2.3 |
24-
| <a name="module_vpn"></a> [vpn](#module\_vpn) | sourcefuse/arc-vpn/aws | 0.0.4 |
24+
| <a name="module_vpn"></a> [vpn](#module\_vpn) | sourcefuse/arc-vpn/aws | 1.0.0 |
2525

2626
## Resources
2727

example/main.tf

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ module "self_signed_cert_root" {
105105
attributes = ["self", "signed", "cert", "root"]
106106

107107
namespace = var.namespace
108-
stage = var.environment
108+
stage = var.environment
109109
name = "demo"
110110

111111
secret_path_format = var.secret_path_format
@@ -141,7 +141,7 @@ module "self_signed_cert_root" {
141141
################################################################################
142142
module "vpn" {
143143
source = "sourcefuse/arc-vpn/aws"
144-
//version = "1.0.0" # pin the correct version
144+
version = "1.0.0" # pin the correct version
145145

146146
vpc_id = data.aws_vpc.this.id
147147

@@ -165,7 +165,5 @@ module "vpn" {
165165
client_vpn_name = "${var.namespace}-${var.environment}-client-vpn-example"
166166
client_vpn_gateway_name = "${var.namespace}-${var.environment}-vpn-gateway-example"
167167

168-
create_vpn_gateway = true
169-
170168
tags = module.tags.tags
171169
}

main.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ module "self_signed_cert" {
6767
attributes = ["self", "signed", "cert", "server"]
6868
secret_path_format = var.self_signed_server_cert_secret_path_format
6969

70-
name = var.client_vpn_name
70+
name = var.client_vpn_name
7171

7272

7373
subject = {
@@ -96,7 +96,7 @@ module "self_signed_cert" {
9696
## vpn
9797
################################################################################
9898
resource "aws_vpn_gateway" "this" {
99-
count = var.create_vpn_gateway ? 1 : 0
99+
count = var.create_vpn_gateway ? 1 : 0
100100
vpc_id = var.vpc_id
101101

102102
tags = merge(var.tags, tomap({

variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,5 +265,5 @@ variable "client_vpn_authorize_all_groups" {
265265
variable "create_vpn_gateway" {
266266
type = bool
267267
description = "Whether to create VPN Gateway, as for a VPC only one Gateway is allowed"
268-
default = true
268+
default = true
269269
}

0 commit comments

Comments
 (0)