-
-
Notifications
You must be signed in to change notification settings - Fork 60
/
main.tf
56 lines (43 loc) · 1.58 KB
/
main.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
provider "aws" {
region = var.region
}
module "vpc" {
source = "cloudposse/vpc/aws"
version = "2.1.1"
ipv4_primary_cidr_block = "172.16.0.0/16"
context = module.this.context
}
module "subnets" {
source = "cloudposse/dynamic-subnets/aws"
version = "1.0.0"
availability_zones = var.availability_zones
vpc_id = module.vpc.vpc_id
igw_id = module.vpc.igw_id
cidr_block = module.vpc.vpc_cidr_block
nat_gateway_enabled = false
nat_instance_enabled = false
context = module.this.context
}
module "mq_broker" {
source = "../../"
vpc_id = module.vpc.vpc_id
subnet_ids = module.subnets.private_subnet_ids
allowed_security_group_ids = [module.vpc.vpc_default_security_group_id]
allowed_ingress_ports = [8162, 5671]
apply_immediately = var.apply_immediately
auto_minor_version_upgrade = var.auto_minor_version_upgrade
deployment_mode = var.deployment_mode
engine_type = var.engine_type
engine_version = var.engine_version
host_instance_type = var.host_instance_type
publicly_accessible = var.publicly_accessible
general_log_enabled = var.general_log_enabled
audit_log_enabled = var.audit_log_enabled
kms_ssm_key_arn = var.kms_ssm_key_arn
encryption_enabled = var.encryption_enabled
kms_mq_key_arn = var.kms_mq_key_arn
use_aws_owned_key = var.use_aws_owned_key
ssm_path = "eg/mq/${var.attributes[0]}"
security_group_create_before_destroy = true
context = module.this.context
}