forked from cloudposse/terraform-aws-efs
-
Notifications
You must be signed in to change notification settings - Fork 5
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
Steven Nemetz
committed
May 16, 2018
1 parent
d2bfdbb
commit eed35f4
Showing
11 changed files
with
169 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,4 @@ | ||
|
||
# Example and manual test cases | ||
|
||
Each directory contains a configuration that serves as a manual test case and an example |
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 @@ | ||
# Example: basic usage |
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,13 @@ | ||
# Lookup DNS zone, vpc, subnets | ||
|
||
module "efs" { | ||
source = "../../" | ||
name = "efs-vol" | ||
environment = "testing" | ||
organization = "" | ||
zone_id = "ZURF67XJUWC5A" # one | ||
security_groups = [] | ||
ingress_cidr = ["10.0.0.0/8"] | ||
subnets = ["subnet-857efce3", "subnet-0852f140", "subnet-6395c038"] | ||
vpc_id = "vpc-417c0027" # one | ||
} |
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,55 @@ | ||
// EFS File System outputs | ||
output "dns_name" { | ||
description = "FQDN of the EFS volume" | ||
value = "${module.efs.dns_name}" | ||
} | ||
|
||
output "id" { | ||
description = "ID of EFS" | ||
value = "${module.efs.id}" | ||
} | ||
|
||
output "kms_key_id" { | ||
description = "" | ||
value = "${module.efs.kms_key_id}" | ||
} | ||
|
||
output "name" { | ||
description = "Service name that was passed in. This is to make creating mount points easier" | ||
value = "${module.efs.name}" | ||
} | ||
|
||
// EFS Mount Target outputs | ||
/* | ||
# Same as EFS mount_target_dns_names | ||
output "mount_target_dns_names" { | ||
description = "List of DNS names of the EFS mount targets" | ||
value = ["${aws_efs_mount_target.default.*.dns_name}"] | ||
} | ||
*/ | ||
output "mount_target_ids" { | ||
description = "List of IDs of the EFS mount targets" | ||
value = "${module.efs.mount_target_ids}" | ||
} | ||
|
||
output "mount_target_ips" { | ||
description = "List of IPs of the EFS mount targets" | ||
value = "${module.efs.mount_target_ips}" | ||
} | ||
|
||
output "mount_target_net_intf_ids" { | ||
description = "List of network interface IDs of the EFS mount targets" | ||
value = "${module.efs.mount_target_net_intf_ids}" | ||
} | ||
|
||
// Other resources | ||
output "security_group" { | ||
description = "" | ||
value = "${module.efs.security_group}" | ||
} | ||
|
||
// Submodules output | ||
output "host" { | ||
description = "Assigned DNS-record for the EFS" | ||
value = "${module.efs.host}" | ||
} |
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,10 @@ | ||
provider "aws" { | ||
region = "${var.region}" | ||
|
||
# Make it faster by skipping something | ||
skip_get_ec2_platforms = true | ||
skip_metadata_api_check = true | ||
skip_region_validation = true | ||
skip_credentials_validation = true | ||
skip_requesting_account_id = true | ||
} |
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,3 @@ | ||
variable "region" { | ||
default = "us-west-2" | ||
} |
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 @@ | ||
# Example: module disabled |
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,14 @@ | ||
# Lookup DNS zone, vpc, subnets | ||
|
||
module "efs" { | ||
source = "../../" | ||
name = "efs-vol-disabled" | ||
environment = "testing" | ||
organization = "" | ||
zone_id = "ZURF67XJUWC5A" # one | ||
security_groups = [] | ||
ingress_cidr = ["10.0.0.0/8"] | ||
subnets = ["subnet-857efce3", "subnet-0852f140", "subnet-6395c038"] | ||
vpc_id = "vpc-417c0027" # one | ||
enabled = false | ||
} |
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,55 @@ | ||
// EFS File System outputs | ||
output "dns_name" { | ||
description = "FQDN of the EFS volume" | ||
value = "${module.efs.dns_name}" | ||
} | ||
|
||
output "id" { | ||
description = "ID of EFS" | ||
value = "${module.efs.id}" | ||
} | ||
|
||
output "kms_key_id" { | ||
description = "" | ||
value = "${module.efs.kms_key_id}" | ||
} | ||
|
||
output "name" { | ||
description = "Service name that was passed in. This is to make creating mount points easier" | ||
value = "${module.efs.name}" | ||
} | ||
|
||
// EFS Mount Target outputs | ||
/* | ||
# Same as EFS mount_target_dns_names | ||
output "mount_target_dns_names" { | ||
description = "List of DNS names of the EFS mount targets" | ||
value = ["${aws_efs_mount_target.default.*.dns_name}"] | ||
} | ||
*/ | ||
output "mount_target_ids" { | ||
description = "List of IDs of the EFS mount targets" | ||
value = "${module.efs.mount_target_ids}" | ||
} | ||
|
||
output "mount_target_ips" { | ||
description = "List of IPs of the EFS mount targets" | ||
value = "${module.efs.mount_target_ips}" | ||
} | ||
|
||
output "mount_target_net_intf_ids" { | ||
description = "List of network interface IDs of the EFS mount targets" | ||
value = "${module.efs.mount_target_net_intf_ids}" | ||
} | ||
|
||
// Other resources | ||
output "security_group" { | ||
description = "" | ||
value = "${module.efs.security_group}" | ||
} | ||
|
||
// Submodules output | ||
output "host" { | ||
description = "Assigned DNS-record for the EFS" | ||
value = "${module.efs.host}" | ||
} |
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,10 @@ | ||
provider "aws" { | ||
region = "${var.region}" | ||
|
||
# Make it faster by skipping something | ||
skip_get_ec2_platforms = true | ||
skip_metadata_api_check = true | ||
skip_region_validation = true | ||
skip_credentials_validation = true | ||
skip_requesting_account_id = true | ||
} |
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,3 @@ | ||
variable "region" { | ||
default = "us-west-2" | ||
} |