File tree Expand file tree Collapse file tree 15 files changed +72
-43
lines changed
terraform/account-wide-infrastructure Expand file tree Collapse file tree 15 files changed +72
-43
lines changed Original file line number Diff line number Diff line change 11module "vpc" {
2+ count = var. enable_powerbi_auto_push ? 1 : 0
23 source = " ../modules/vpc"
34 vpc_cidr_block = var. vpc_cidr_block
45 enable_dns_hostnames = var. enable_dns_hostnames
@@ -8,16 +9,17 @@ module "vpc" {
89 name_prefix = " nhsd-nrlf--dev"
910}
1011
11- module "powerbi_gw_instance_v2" {
12- source = " ../modules/ec2"
13- use_custom_ami = true
14- instance_type = var. instance_type
12+ module "powerbi_gw_instance" {
13+ count = var. enable_powerbi_auto_push ? 1 : 0
14+ source = " ../modules/powerbi-gw-ec2"
15+ use_custom_ami = var. use_powerbi_gw_custom_ami
16+ instance_type = var. powerbi_gw_instance_type
1517 name_prefix = " nhsd-nrlf--dev-powerbi-gw-v2"
1618 target_bucket_arn = module. dev-glue . target_bucket_arn
1719 glue_kms_key_arn = module. dev-glue . aws_kms_key_arn
1820 athena_kms_key_arn = module. dev-athena . kms_key_arn
1921 athena_bucket_arn = module. dev-athena . bucket_arn
2022
21- subnet_id = module. vpc . private_subnet_id
22- security_groups = [module . vpc . powerbi_gw_security_group_id ]
23+ subnet_id = module. vpc [ 0 ] . private_subnet_id
24+ security_groups = [module . vpc [ 0 ] . powerbi_gw_security_group_id ]
2325}
Original file line number Diff line number Diff line change @@ -44,14 +44,20 @@ variable "vpc_private_subnets_cidr_block" {
4444 default = " 10.0.1.0/24"
4545}
4646
47- variable "instance_type" {
47+ variable "enable_powerbi_auto_push" {
48+ type = bool
49+ description = " Enable automatic pushing of info into PowerBI"
50+ default = false
51+ }
52+
53+ variable "powerbi_gw_instance_type" {
4854 type = string
49- description = " Type for EC2 Instance"
55+ description = " Type for PowerBI GW EC2 Instance"
5056 default = " t2.micro"
5157}
5258
53- variable "use_custom_ami " {
59+ variable "use_powerbi_gw_custom_ami " {
5460 type = bool
55- description = " Use custom image"
56- default = false
61+ description = " Use custom image for PowerBI GW instance "
62+ default = true
5763}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change @@ -55,7 +55,6 @@ resource "aws_route_table" "private_rt" {
5555}
5656
5757resource "aws_eip" "natgw-ip" {
58- domain = " vpc"
5958}
6059
6160resource "aws_nat_gateway" "nat" {
You can’t perform that action at this time.
0 commit comments