Commit 0588b340 authored by Anton Babenko's avatar Anton Babenko

Fixed merge conflicts

parent 4ae98060
...@@ -919,27 +919,6 @@ resource "aws_vpc_endpoint" "sqs" { ...@@ -919,27 +919,6 @@ resource "aws_vpc_endpoint" "sqs" {
private_dns_enabled = var.sqs_endpoint_private_dns_enabled private_dns_enabled = var.sqs_endpoint_private_dns_enabled
} }
#######################
# VPC Endpoint for SQS
#######################
data "aws_vpc_endpoint_service" "sqs" {
count = "${var.create_vpc && var.enable_sqs_endpoint ? 1 : 0}"
service = "sqs"
}
resource "aws_vpc_endpoint" "sqs" {
count = "${var.create_vpc && var.enable_sqs_endpoint ? 1 : 0}"
vpc_id = "${local.vpc_id}"
service_name = "${data.aws_vpc_endpoint_service.sqs.service_name}"
vpc_endpoint_type = "Interface"
security_group_ids = ["${var.sqs_endpoint_security_group_ids}"]
subnet_ids = ["${coalescelist(var.sqs_endpoint_subnet_ids, aws_subnet.private.*.id)}"]
private_dns_enabled = "${var.sqs_endpoint_private_dns_enabled}"
}
####################### #######################
# VPC Endpoint for SSM # VPC Endpoint for SSM
####################### #######################
...@@ -1173,72 +1152,6 @@ resource "aws_vpc_endpoint" "ecs_telemetry" { ...@@ -1173,72 +1152,6 @@ resource "aws_vpc_endpoint" "ecs_telemetry" {
private_dns_enabled = var.ecs_telemetry_endpoint_private_dns_enabled private_dns_enabled = var.ecs_telemetry_endpoint_private_dns_enabled
} }
#######################
# VPC Endpoint for ECS
#######################
data "aws_vpc_endpoint_service" "ecs" {
count = "${var.create_vpc && var.enable_ecs_endpoint ? 1 : 0}"
service = "ecs"
}
resource "aws_vpc_endpoint" "ecs" {
count = "${var.create_vpc && var.enable_ecs_endpoint ? 1 : 0}"
vpc_id = "${local.vpc_id}"
service_name = "${data.aws_vpc_endpoint_service.ecs.service_name}"
vpc_endpoint_type = "Interface"
security_group_ids = ["${var.ecs_endpoint_security_group_ids}"]
subnet_ids = ["${coalescelist(var.ecs_endpoint_subnet_ids, aws_subnet.private.*.id)}"]
private_dns_enabled = "${var.ecs_endpoint_private_dns_enabled}"
}
#######################
# VPC Endpoint for ECS Agent
#######################
data "aws_vpc_endpoint_service" "ecs_agent" {
count = "${var.create_vpc && var.enable_ecs_agent_endpoint ? 1 : 0}"
service = "ecs-agent"
}
resource "aws_vpc_endpoint" "ecs_agent" {
count = "${var.create_vpc && var.enable_ecs_agent_endpoint ? 1 : 0}"
vpc_id = "${local.vpc_id}"
service_name = "${data.aws_vpc_endpoint_service.ecs_agent.service_name}"
vpc_endpoint_type = "Interface"
security_group_ids = ["${var.ecs_agent_endpoint_security_group_ids}"]
subnet_ids = ["${coalescelist(var.ecs_agent_endpoint_subnet_ids, aws_subnet.private.*.id)}"]
private_dns_enabled = "${var.ecs_agent_endpoint_private_dns_enabled}"
}
#######################
# VPC Endpoint for ECS Telemetry
#######################
data "aws_vpc_endpoint_service" "ecs_telemetry" {
count = "${var.create_vpc && var.enable_ecs_telemetry_endpoint ? 1 : 0}"
service = "ecs-telemetry"
}
resource "aws_vpc_endpoint" "ecs_telemetry" {
count = "${var.create_vpc && var.enable_ecs_telemetry_endpoint ? 1 : 0}"
vpc_id = "${local.vpc_id}"
service_name = "${data.aws_vpc_endpoint_service.ecs_telemetry.service_name}"
vpc_endpoint_type = "Interface"
security_group_ids = ["${var.ecs_telemetry_endpoint_security_group_ids}"]
subnet_ids = ["${coalescelist(var.ecs_telemetry_endpoint_subnet_ids, aws_subnet.private.*.id)}"]
private_dns_enabled = "${var.ecs_telemetry_endpoint_private_dns_enabled}"
}
########################## ##########################
# Route table association # Route table association
########################## ##########################
......
...@@ -348,21 +348,6 @@ output "vpc_endpoint_dynamodb_pl_id" { ...@@ -348,21 +348,6 @@ output "vpc_endpoint_dynamodb_pl_id" {
value = concat(aws_vpc_endpoint.dynamodb.*.prefix_list_id, [""])[0] value = concat(aws_vpc_endpoint.dynamodb.*.prefix_list_id, [""])[0]
} }
output "vpc_endpoint_sqs_id" {
description = "The ID of VPC endpoint for SQS"
value = concat(aws_vpc_endpoint.sqs.*.id, [""])[0]
}
output "vpc_endpoint_sqs_network_interface_ids" {
description = "One or more network interfaces for the VPC Endpoint for SQS."
value = flatten(aws_vpc_endpoint.sqs.*.network_interface_ids)
}
output "vpc_endpoint_sqs_dns_entry" {
description = "The DNS entries for the VPC Endpoint for SQS."
value = flatten(aws_vpc_endpoint.sqs.*.dns_entry)
}
output "vpc_endpoint_sqs_id" { output "vpc_endpoint_sqs_id" {
description = "The ID of VPC endpoint for SQS" description = "The ID of VPC endpoint for SQS"
value = "${element(concat(aws_vpc_endpoint.sqs.*.id, list("")), 0)}" value = "${element(concat(aws_vpc_endpoint.sqs.*.id, list("")), 0)}"
...@@ -498,51 +483,6 @@ output "vpc_endpoint_apigw_dns_entry" { ...@@ -498,51 +483,6 @@ output "vpc_endpoint_apigw_dns_entry" {
value = flatten(aws_vpc_endpoint.apigw.*.dns_entry) value = flatten(aws_vpc_endpoint.apigw.*.dns_entry)
} }
output "vpc_endpoint_ecs_id" {
description = "The ID of VPC endpoint for ECS"
value = concat(aws_vpc_endpoint.ecs.*.id, [""])[0]
}
output "vpc_endpoint_ecs_network_interface_ids" {
description = "One or more network interfaces for the VPC Endpoint for ECS."
value = flatten(aws_vpc_endpoint.ecs.*.network_interface_ids)
}
output "vpc_endpoint_ecs_dns_entry" {
description = "The DNS entries for the VPC Endpoint for ECS."
value = flatten(aws_vpc_endpoint.ecs.*.dns_entry)
}
output "vpc_endpoint_ecs_agent_id" {
description = "The ID of VPC endpoint for ECS Agent"
value = concat(aws_vpc_endpoint.ecs_agent.*.id, [""])[0]
}
output "vpc_endpoint_ecs_agent_network_interface_ids" {
description = "One or more network interfaces for the VPC Endpoint for ECS Agent."
value = flatten(aws_vpc_endpoint.ecs_agent.*.network_interface_ids)
}
output "vpc_endpoint_ecs_agent_dns_entry" {
description = "The DNS entries for the VPC Endpoint for ECS Agent."
value = flatten(aws_vpc_endpoint.ecs_agent.*.dns_entry)
}
output "vpc_endpoint_ecs_telemetry_id" {
description = "The ID of VPC endpoint for ECS Telemetry"
value = concat(aws_vpc_endpoint.ecs_telemetry.*.id, [""])[0]
}
output "vpc_endpoint_ecs_telemetry_network_interface_ids" {
description = "One or more network interfaces for the VPC Endpoint for ECS Telemetry."
value = flatten(aws_vpc_endpoint.ecs_telemetry.*.network_interface_ids)
}
output "vpc_endpoint_ecs_telemetry_dns_entry" {
description = "The DNS entries for the VPC Endpoint for ECS Telemetry."
value = flatten(aws_vpc_endpoint.ecs_telemetry.*.dns_entry)
}
output "vpc_endpoint_ecs_id" { output "vpc_endpoint_ecs_id" {
description = "The ID of VPC endpoint for ECS" description = "The ID of VPC endpoint for ECS"
value = "${element(concat(aws_vpc_endpoint.ecs.*.id, list("")), 0)}" value = "${element(concat(aws_vpc_endpoint.ecs.*.id, list("")), 0)}"
......
...@@ -238,26 +238,6 @@ variable "sqs_endpoint_private_dns_enabled" { ...@@ -238,26 +238,6 @@ variable "sqs_endpoint_private_dns_enabled" {
default = false default = false
} }
variable "enable_sqs_endpoint" {
description = "Should be true if you want to provision an SQS endpoint to the VPC"
default = false
}
variable "sqs_endpoint_security_group_ids" {
description = "The ID of one or more security groups to associate with the network interface for SQS endpoint"
default = []
}
variable "sqs_endpoint_subnet_ids" {
description = "The ID of one or more subnets in which to create a network interface for SQS endpoint. Only a single subnet within an AZ is supported. If omitted, private subnets will be used."
default = []
}
variable "sqs_endpoint_private_dns_enabled" {
description = "Whether or not to associate a private hosted zone with the specified VPC for SQS endpoint"
default = false
}
variable "enable_ssm_endpoint" { variable "enable_ssm_endpoint" {
description = "Should be true if you want to provision an SSM endpoint to the VPC" description = "Should be true if you want to provision an SSM endpoint to the VPC"
type = bool type = bool
...@@ -522,66 +502,6 @@ variable "ecs_telemetry_endpoint_private_dns_enabled" { ...@@ -522,66 +502,6 @@ variable "ecs_telemetry_endpoint_private_dns_enabled" {
default = false default = false
} }
variable "enable_ecs_endpoint" {
description = "Should be true if you want to provision a ECS endpoint to the VPC"
default = false
}
variable "ecs_endpoint_security_group_ids" {
description = "The ID of one or more security groups to associate with the network interface for ECS endpoint"
default = []
}
variable "ecs_endpoint_subnet_ids" {
description = "The ID of one or more subnets in which to create a network interface for ECS endpoint. Only a single subnet within an AZ is supported. If omitted, private subnets will be used."
default = []
}
variable "ecs_endpoint_private_dns_enabled" {
description = "Whether or not to associate a private hosted zone with the specified VPC for ECS endpoint"
default = false
}
variable "enable_ecs_agent_endpoint" {
description = "Should be true if you want to provision a ECS Agent endpoint to the VPC"
default = false
}
variable "ecs_agent_endpoint_security_group_ids" {
description = "The ID of one or more security groups to associate with the network interface for ECS Agent endpoint"
default = []
}
variable "ecs_agent_endpoint_subnet_ids" {
description = "The ID of one or more subnets in which to create a network interface for ECS Agent endpoint. Only a single subnet within an AZ is supported. If omitted, private subnets will be used."
default = []
}
variable "ecs_agent_endpoint_private_dns_enabled" {
description = "Whether or not to associate a private hosted zone with the specified VPC for ECS Agent endpoint"
default = false
}
variable "enable_ecs_telemetry_endpoint" {
description = "Should be true if you want to provision a ECS Telemetry endpoint to the VPC"
default = false
}
variable "ecs_telemetry_endpoint_security_group_ids" {
description = "The ID of one or more security groups to associate with the network interface for ECS Telemetry endpoint"
default = []
}
variable "ecs_telemetry_endpoint_subnet_ids" {
description = "The ID of one or more subnets in which to create a network interface for ECS Telemetry endpoint. Only a single subnet within an AZ is supported. If omitted, private subnets will be used."
default = []
}
variable "ecs_telemetry_endpoint_private_dns_enabled" {
description = "Whether or not to associate a private hosted zone with the specified VPC for ECS Telemetry endpoint"
default = false
}
variable "map_public_ip_on_launch" { variable "map_public_ip_on_launch" {
description = "Should be false if you do not want to auto-assign public IP on launch" description = "Should be false if you do not want to auto-assign public IP on launch"
type = bool type = bool
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment