cleaning up terraform to put in pre-prepared VPC

This commit is contained in:
pokeeffe-molecula 2022-01-07 17:25:48 -06:00
parent b864d6b6f1
commit bb434639ad
10 changed files with 1107 additions and 1054 deletions

View file

@ -24,7 +24,7 @@ resource "aws_instance" "fb_cluster_nodes" {
key_name = aws_key_pair.gitlab-featurebase-ci.key_name
vpc_security_group_ids = [aws_security_group.featurebase.id]
monitoring = true
subnet_id = var.subnet != "" ? var.subnet : module.vpc.private_subnets[count.index % length(module.vpc.private_subnets)]
subnet_id = var.subnet != "" ? var.subnet : var.vpc_private_subnets[count.index % length(var.vpc_private_subnets)]
availability_zone = var.zone != "" ? var.zone : var.azs[count.index % length(var.azs)]
iam_instance_profile = "${aws_iam_instance_profile.fb_cluster_node_profile.name}"
@ -57,7 +57,7 @@ resource "aws_instance" "fb_ingest" {
instance_type = var.fb_ingest_type
associate_public_ip_address = true
monitoring = true
subnet_id = var.subnet != "" ? var.subnet : module.vpc.public_subnets[count.index % length(module.vpc.public_subnets)]
subnet_id = var.subnet != "" ? var.subnet : var.vpc_public_subnets[count.index % length(var.vpc_public_subnets)]
availability_zone = var.zone != "" ? var.zone : var.azs[count.index % length(var.azs)]
iam_instance_profile = "${aws_iam_instance_profile.fb_cluster_node_profile.name}"
@ -83,30 +83,37 @@ resource "aws_instance" "fb_ingest" {
}
resource "aws_key_pair" "gitlab-featurebase-ci" {
key_name = "gitlab-featurebase-ci"
key_name = "${var.cluster_prefix}-gitlab-ci"
public_key = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC91hhpVHNonAG7ku2ugpxEskf9KHeyHJPQJT26OHrMUw7R+T5A8TjqSzTau07sXQ/E9SO3ebV8SJ5PqeaQOnQB8VEvVNK0DjQH7ppvNg1Rfs42FZT9ttzTMvOjsSbK3vZTHXdoKQEdC9NxBwSkFIRGQojK1HUOq9xGrw31fA1OjSwlpLcbx7yyg18lcqW6UOptnVR8U9Yy9qQ5jZF1HtkQ6L9J+gv4o1UyNAUK2bopeGiXpBc3PQ/CFaFT2h/aqLBP66qAHsHVyAFD3PIRtplC5EHa8jXDgLacEls0uF7Q3kRPxvzcuo4g4VkOn1rDy9qH3vd2hT3aKVnM73FIDUiL"
}
resource "aws_security_group" "featurebase" {
name = "allow_featurebase"
name = "${var.cluster_prefix}-allow_featurebase"
description = "Allow featurebase inbound traffic"
vpc_id = module.vpc.vpc_id
vpc_id = var.vpc_id
ingress {
description = "TLS from Internal"
from_port = 10101
to_port = 10101
protocol = "tcp"
cidr_blocks = [module.vpc.vpc_cidr_block]
description = "icmp from Anywhere"
from_port = -1
to_port = -1
protocol = "icmp"
cidr_blocks = ["0.0.0.0/0"]
}
ingress {
description = "HTTP from Internal"
from_port = 10101
to_port = 10101
protocol = "tcp"
cidr_blocks = ["10.0.0.0/8", "172.31.0.0/16"]
}
ingress {
description = "GRPC from Internal"
from_port = 20101
to_port = 20101
protocol = "tcp"
cidr_blocks = [module.vpc.vpc_cidr_block]
cidr_blocks = ["10.0.0.0/8", "172.31.0.0/16"]
}
ingress {
@ -114,7 +121,7 @@ resource "aws_security_group" "featurebase" {
from_port = 55432
to_port = 55432
protocol = "tcp"
cidr_blocks = [module.vpc.vpc_cidr_block]
cidr_blocks = ["10.0.0.0/8", "172.31.0.0/16"]
}
ingress {
@ -122,7 +129,7 @@ resource "aws_security_group" "featurebase" {
from_port = 10301
to_port = 10301
protocol = "tcp"
cidr_blocks = [module.vpc.vpc_cidr_block]
cidr_blocks = [var.vpc_cidr_block]
}
ingress {
@ -130,7 +137,7 @@ resource "aws_security_group" "featurebase" {
from_port = 10401
to_port = 10401
protocol = "tcp"
cidr_blocks = [module.vpc.vpc_cidr_block]
cidr_blocks = [var.vpc_cidr_block]
}
ingress {
@ -156,9 +163,17 @@ resource "aws_security_group" "featurebase" {
}
resource "aws_security_group" "ingest" {
name = "allow_ingest"
name = "${var.cluster_prefix}-allow_ingest"
description = "Allow ingest inbound traffic"
vpc_id = module.vpc.vpc_id
vpc_id = var.vpc_id
ingress {
description = "icmp from Anywhere"
from_port = -1
to_port = -1
protocol = "icmp"
cidr_blocks = ["0.0.0.0/0"]
}
ingress {
from_port = 10101
@ -191,12 +206,12 @@ resource "aws_security_group" "ingest" {
}
resource "aws_iam_instance_profile" "fb_cluster_node_profile" {
name = "fb_cluster_node_profile"
name = "${var.cluster_prefix}-fb_cluster_node_profile"
role = aws_iam_role.fb_cluster_node_role.name
}
resource "aws_iam_role" "fb_cluster_node_role" {
name = "fb_cluster_node"
name = "${var.cluster_prefix}-fb_cluster_node"
assume_role_policy = jsonencode({
Version = "2012-10-17"

View file

@ -7,5 +7,5 @@ output "data_node_ips" {
}
output "vpc_id" {
value = module.vpc.vpc_id
value = var.vpc_id
}

View file

@ -96,3 +96,23 @@ variable "branch" {
description = "The branch we are on"
type = string
}
variable "vpc_id" {
description = "The VPC in which we will build the cluster"
type = string
}
variable "vpc_cidr_block" {
description = "A delicious crisp cider associated with the VPC in which we will build the cluster"
type = string
}
variable "vpc_public_subnets" {
description = "A public net underneath in the VPC in which we will build the cluster"
type = list(string)
}
variable "vpc_private_subnets" {
description = "A private net underneath in the VPC in which we will build the cluster"
type = list(string)
}

View file

@ -1,16 +0,0 @@
module "vpc" {
source = "terraform-aws-modules/vpc/aws"
name = "${var.cluster_prefix}"
cidr = var.vpc_cidr
azs = var.azs
private_subnets = var.private_subnets
public_subnets = var.public_subnets
enable_nat_gateway = true
enable_vpn_gateway = false
tags = {
Name = "${var.cluster_prefix}"
}
}

View file

@ -8,10 +8,8 @@ module "ci-cluster" {
fb_data_node_count = 1
gitlab_token = var.gitlab_token
branch = var.branch
}
resource "aws_vpc_peering_connection" "smoketest-to-vpn" {
vpc_id = module.ci-cluster.vpc_id
peer_vpc_id = "vpc-0cb7cf76f2079aa0e"
auto_accept = true
vpc_id = "vpc-05a26a122f961dc2b"
vpc_cidr_block = "10.0.0.0/16"
vpc_public_subnets = ["subnet-066b4b922b54e51a2","subnet-037b8884269a69025","subnet-08482631514426210",]
vpc_private_subnets = ["subnet-050b1219d78f2db1b","subnet-07155281789c6d33b","subnet-0d623c769e086e46e",]
}

View file

@ -6,9 +6,4 @@ output "ingest_ips" {
output "data_node_ips" {
description = "List of data node IPs"
value = module.ci-cluster.data_node_ips
}
output "vpc_id" {
description = "ID of the VPC"
value = module.ci-cluster.vpc_id
}

File diff suppressed because it is too large Load diff

View file

@ -11,10 +11,8 @@ module "samsung-cluster" {
fb_ingest_node_count = 1
gitlab_token = var.gitlab_token
branch = var.branch
}
resource "aws_vpc_peering_connection" "gauntlet-to-vpn" {
vpc_id = module.samsung-cluster.vpc_id
peer_vpc_id = "vpc-0cb7cf76f2079aa0e"
auto_accept = true
vpc_id = "vpc-05a26a122f961dc2b"
vpc_cidr_block = "10.0.0.0/16"
vpc_public_subnets = ["subnet-066b4b922b54e51a2","subnet-037b8884269a69025","subnet-08482631514426210",]
vpc_private_subnets = ["subnet-050b1219d78f2db1b","subnet-0d623c769e086e46e","subnet-07155281789c6d33b",]
}

View file

@ -6,9 +6,4 @@ output "ingest_ips" {
output "data_node_ips" {
description = "List of data node IPs"
value = module.samsung-cluster.data_node_ips
}
output "vpc_id" {
description = "ID of the gauntlet VPC"
value = module.samsung-cluster.vpc_id
}

View file

@ -0,0 +1,938 @@
{
"version": 4,
"terraform_version": "1.1.2",
"serial": 20,
"lineage": "febac4ac-400a-d207-d2d1-64c55f14767b",
"outputs": {
"data_node_ips": {
"value": [
"10.0.1.197",
"10.0.2.133",
"10.0.3.244"
],
"type": [
"tuple",
[
"string",
"string",
"string"
]
]
},
"ingest_ips": {
"value": [
"3.145.96.245"
],
"type": [
"tuple",
[
"string"
]
]
}
},
"resources": [
{
"module": "module.samsung-cluster",
"mode": "data",
"type": "aws_ami",
"name": "amazon_linux_2",
"provider": "provider[\"registry.terraform.io/hashicorp/aws\"]",
"instances": [
{
"schema_version": 0,
"attributes": {
"architecture": "arm64",
"arn": "arn:aws:ec2:us-east-2::image/ami-0b09f36be67d32fff",
"block_device_mappings": [
{
"device_name": "/dev/xvda",
"ebs": {
"delete_on_termination": "true",
"encrypted": "false",
"iops": "0",
"snapshot_id": "snap-0617b00e90bae012b",
"throughput": "0",
"volume_size": "8",
"volume_type": "gp2"
},
"no_device": "",
"virtual_name": ""
}
],
"creation_date": "2021-12-01T19:36:11.000Z",
"description": "Amazon Linux 2 LTS Arm64 AMI 2.0.20211201.0 arm64 HVM gp2",
"ena_support": true,
"executable_users": null,
"filter": [
{
"name": "architecture",
"values": [
"arm64"
]
},
{
"name": "name",
"values": [
"amzn2-ami-hvm-*"
]
},
{
"name": "virtualization-type",
"values": [
"hvm"
]
}
],
"hypervisor": "xen",
"id": "ami-0b09f36be67d32fff",
"image_id": "ami-0b09f36be67d32fff",
"image_location": "amazon/amzn2-ami-hvm-2.0.20211201.0-arm64-gp2",
"image_owner_alias": "amazon",
"image_type": "machine",
"kernel_id": null,
"most_recent": true,
"name": "amzn2-ami-hvm-2.0.20211201.0-arm64-gp2",
"name_regex": null,
"owner_id": "137112412989",
"owners": [
"amazon"
],
"platform": null,
"platform_details": "Linux/UNIX",
"product_codes": [],
"public": true,
"ramdisk_id": null,
"root_device_name": "/dev/xvda",
"root_device_type": "ebs",
"root_snapshot_id": "snap-0617b00e90bae012b",
"sriov_net_support": "simple",
"state": "available",
"state_reason": {
"code": "UNSET",
"message": "UNSET"
},
"tags": {},
"usage_operation": "RunInstances",
"virtualization_type": "hvm"
},
"sensitive_attributes": []
}
]
},
{
"module": "module.samsung-cluster",
"mode": "managed",
"type": "aws_iam_instance_profile",
"name": "fb_cluster_node_profile",
"provider": "provider[\"registry.terraform.io/hashicorp/aws\"]",
"instances": [
{
"schema_version": 0,
"attributes": {
"arn": "arn:aws:iam::977373308795:instance-profile/samsung-gauntlet-fb_cluster_node_profile",
"create_date": "2022-01-07T23:16:27Z",
"id": "samsung-gauntlet-fb_cluster_node_profile",
"name": "samsung-gauntlet-fb_cluster_node_profile",
"name_prefix": null,
"path": "/",
"role": "samsung-gauntlet-fb_cluster_node",
"tags": {},
"tags_all": {},
"unique_id": "AIPA6HD75E55ZM7XC2IBD"
},
"sensitive_attributes": [],
"private": "bnVsbA==",
"dependencies": [
"module.samsung-cluster.aws_iam_role.fb_cluster_node_role"
]
}
]
},
{
"module": "module.samsung-cluster",
"mode": "managed",
"type": "aws_iam_role",
"name": "fb_cluster_node_role",
"provider": "provider[\"registry.terraform.io/hashicorp/aws\"]",
"instances": [
{
"schema_version": 0,
"attributes": {
"arn": "arn:aws:iam::977373308795:role/samsung-gauntlet-fb_cluster_node",
"assume_role_policy": "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Sid\":\"\",\"Effect\":\"Allow\",\"Principal\":{\"Service\":\"ec2.amazonaws.com\"},\"Action\":\"sts:AssumeRole\"}]}",
"create_date": "2022-01-07T23:16:05Z",
"description": "",
"force_detach_policies": false,
"id": "samsung-gauntlet-fb_cluster_node",
"inline_policy": [
{
"name": "ec2_read_all",
"policy": "{\"Statement\":[{\"Action\":[\"ec2:Describe*\"],\"Effect\":\"Allow\",\"Resource\":\"*\"}],\"Version\":\"2012-10-17\"}"
}
],
"managed_policy_arns": [],
"max_session_duration": 3600,
"name": "samsung-gauntlet-fb_cluster_node",
"name_prefix": "",
"path": "/",
"permissions_boundary": null,
"tags": {},
"tags_all": {},
"unique_id": "AROA6HD75E55VM3GADWTD"
},
"sensitive_attributes": [],
"private": "bnVsbA=="
}
]
},
{
"module": "module.samsung-cluster",
"mode": "managed",
"type": "aws_instance",
"name": "fb_cluster_nodes",
"provider": "provider[\"registry.terraform.io/hashicorp/aws\"]",
"instances": [
{
"index_key": 0,
"schema_version": 1,
"attributes": {
"ami": "ami-0b09f36be67d32fff",
"arn": "arn:aws:ec2:us-east-2:977373308795:instance/i-09664bb4472386327",
"associate_public_ip_address": false,
"availability_zone": "us-east-2a",
"capacity_reservation_specification": [
{
"capacity_reservation_preference": "open",
"capacity_reservation_target": []
}
],
"cpu_core_count": 4,
"cpu_threads_per_core": 1,
"credit_specification": [],
"disable_api_termination": false,
"ebs_block_device": [
{
"delete_on_termination": true,
"device_name": "/dev/sdb",
"encrypted": false,
"iops": 10000,
"kms_key_id": "",
"snapshot_id": "",
"tags": {},
"throughput": 125,
"volume_id": "vol-04c28c1cb5143ddf7",
"volume_size": 100,
"volume_type": "gp3"
}
],
"ebs_optimized": false,
"enclave_options": [
{
"enabled": false
}
],
"ephemeral_block_device": [],
"get_password_data": false,
"hibernation": false,
"host_id": null,
"iam_instance_profile": "samsung-gauntlet-fb_cluster_node_profile",
"id": "i-09664bb4472386327",
"instance_initiated_shutdown_behavior": "stop",
"instance_state": "running",
"instance_type": "m6g.xlarge",
"ipv6_address_count": 0,
"ipv6_addresses": [],
"key_name": "samsung-gauntlet-gitlab-ci",
"launch_template": [],
"metadata_options": [
{
"http_endpoint": "enabled",
"http_put_response_hop_limit": 1,
"http_tokens": "optional"
}
],
"monitoring": true,
"network_interface": [],
"outpost_arn": "",
"password_data": "",
"placement_group": "",
"placement_partition_number": null,
"primary_network_interface_id": "eni-0809b96866ccfa203",
"private_dns": "ip-10-0-1-197.us-east-2.compute.internal",
"private_ip": "10.0.1.197",
"public_dns": "",
"public_ip": "",
"root_block_device": [
{
"delete_on_termination": true,
"device_name": "/dev/xvda",
"encrypted": false,
"iops": 3000,
"kms_key_id": "",
"tags": {},
"throughput": 125,
"volume_id": "vol-031f177e3f36fe051",
"volume_size": 20,
"volume_type": "gp3"
}
],
"secondary_private_ips": [],
"security_groups": [],
"source_dest_check": true,
"subnet_id": "subnet-050b1219d78f2db1b",
"tags": {
"Name": "samsung-gauntlet-featurebase-cluster-0",
"Prefix": "samsung-gauntlet",
"Role": "cluster_node"
},
"tags_all": {
"Name": "samsung-gauntlet-featurebase-cluster-0",
"Prefix": "samsung-gauntlet",
"Role": "cluster_node"
},
"tenancy": "default",
"timeouts": null,
"user_data": "ed849ffb2caa5f32ccaf0571e91c3f6d9a54faac",
"user_data_base64": null,
"volume_tags": null,
"vpc_security_group_ids": [
"sg-04d60067fbf393f98"
]
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6MTIwMDAwMDAwMDAwMCwidXBkYXRlIjo2MDAwMDAwMDAwMDB9LCJzY2hlbWFfdmVyc2lvbiI6IjEifQ==",
"dependencies": [
"module.samsung-cluster.aws_iam_role.fb_cluster_node_role",
"module.samsung-cluster.aws_key_pair.gitlab-featurebase-ci",
"module.samsung-cluster.aws_security_group.featurebase",
"module.samsung-cluster.data.aws_ami.amazon_linux_2",
"module.samsung-cluster.aws_iam_instance_profile.fb_cluster_node_profile"
]
},
{
"index_key": 1,
"schema_version": 1,
"attributes": {
"ami": "ami-0b09f36be67d32fff",
"arn": "arn:aws:ec2:us-east-2:977373308795:instance/i-031b4e15ea7645578",
"associate_public_ip_address": false,
"availability_zone": "us-east-2b",
"capacity_reservation_specification": [
{
"capacity_reservation_preference": "open",
"capacity_reservation_target": []
}
],
"cpu_core_count": 4,
"cpu_threads_per_core": 1,
"credit_specification": [],
"disable_api_termination": false,
"ebs_block_device": [
{
"delete_on_termination": true,
"device_name": "/dev/sdb",
"encrypted": false,
"iops": 10000,
"kms_key_id": "",
"snapshot_id": "",
"tags": {},
"throughput": 125,
"volume_id": "vol-0fd362b5516d0c017",
"volume_size": 100,
"volume_type": "gp3"
}
],
"ebs_optimized": false,
"enclave_options": [
{
"enabled": false
}
],
"ephemeral_block_device": [],
"get_password_data": false,
"hibernation": false,
"host_id": null,
"iam_instance_profile": "samsung-gauntlet-fb_cluster_node_profile",
"id": "i-031b4e15ea7645578",
"instance_initiated_shutdown_behavior": "stop",
"instance_state": "running",
"instance_type": "m6g.xlarge",
"ipv6_address_count": 0,
"ipv6_addresses": [],
"key_name": "samsung-gauntlet-gitlab-ci",
"launch_template": [],
"metadata_options": [
{
"http_endpoint": "enabled",
"http_put_response_hop_limit": 1,
"http_tokens": "optional"
}
],
"monitoring": true,
"network_interface": [],
"outpost_arn": "",
"password_data": "",
"placement_group": "",
"placement_partition_number": null,
"primary_network_interface_id": "eni-0b844cf311584941e",
"private_dns": "ip-10-0-2-133.us-east-2.compute.internal",
"private_ip": "10.0.2.133",
"public_dns": "",
"public_ip": "",
"root_block_device": [
{
"delete_on_termination": true,
"device_name": "/dev/xvda",
"encrypted": false,
"iops": 3000,
"kms_key_id": "",
"tags": null,
"throughput": 125,
"volume_id": "vol-0c3fe8fb90d0542c0",
"volume_size": 20,
"volume_type": "gp3"
}
],
"secondary_private_ips": [],
"security_groups": [],
"source_dest_check": true,
"subnet_id": "subnet-0d623c769e086e46e",
"tags": {
"Name": "samsung-gauntlet-featurebase-cluster-1",
"Prefix": "samsung-gauntlet",
"Role": "cluster_node"
},
"tags_all": {
"Name": "samsung-gauntlet-featurebase-cluster-1",
"Prefix": "samsung-gauntlet",
"Role": "cluster_node"
},
"tenancy": "default",
"timeouts": null,
"user_data": "ed849ffb2caa5f32ccaf0571e91c3f6d9a54faac",
"user_data_base64": null,
"volume_tags": null,
"vpc_security_group_ids": [
"sg-04d60067fbf393f98"
]
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6MTIwMDAwMDAwMDAwMCwidXBkYXRlIjo2MDAwMDAwMDAwMDB9LCJzY2hlbWFfdmVyc2lvbiI6IjEifQ==",
"dependencies": [
"module.samsung-cluster.aws_iam_instance_profile.fb_cluster_node_profile",
"module.samsung-cluster.aws_key_pair.gitlab-featurebase-ci",
"module.samsung-cluster.aws_security_group.featurebase",
"module.samsung-cluster.data.aws_ami.amazon_linux_2"
]
},
{
"index_key": 2,
"schema_version": 1,
"attributes": {
"ami": "ami-0b09f36be67d32fff",
"arn": "arn:aws:ec2:us-east-2:977373308795:instance/i-0a37c057bee7ba28d",
"associate_public_ip_address": false,
"availability_zone": "us-east-2c",
"capacity_reservation_specification": [
{
"capacity_reservation_preference": "open",
"capacity_reservation_target": []
}
],
"cpu_core_count": 4,
"cpu_threads_per_core": 1,
"credit_specification": [],
"disable_api_termination": false,
"ebs_block_device": [
{
"delete_on_termination": true,
"device_name": "/dev/sdb",
"encrypted": false,
"iops": 10000,
"kms_key_id": "",
"snapshot_id": "",
"tags": {},
"throughput": 125,
"volume_id": "vol-0203d9c0080bccc2a",
"volume_size": 100,
"volume_type": "gp3"
}
],
"ebs_optimized": false,
"enclave_options": [
{
"enabled": false
}
],
"ephemeral_block_device": [],
"get_password_data": false,
"hibernation": false,
"host_id": null,
"iam_instance_profile": "samsung-gauntlet-fb_cluster_node_profile",
"id": "i-0a37c057bee7ba28d",
"instance_initiated_shutdown_behavior": "stop",
"instance_state": "running",
"instance_type": "m6g.xlarge",
"ipv6_address_count": 0,
"ipv6_addresses": [],
"key_name": "samsung-gauntlet-gitlab-ci",
"launch_template": [],
"metadata_options": [
{
"http_endpoint": "enabled",
"http_put_response_hop_limit": 1,
"http_tokens": "optional"
}
],
"monitoring": true,
"network_interface": [],
"outpost_arn": "",
"password_data": "",
"placement_group": "",
"placement_partition_number": null,
"primary_network_interface_id": "eni-03d10f8c14edc12b2",
"private_dns": "ip-10-0-3-244.us-east-2.compute.internal",
"private_ip": "10.0.3.244",
"public_dns": "",
"public_ip": "",
"root_block_device": [
{
"delete_on_termination": true,
"device_name": "/dev/xvda",
"encrypted": false,
"iops": 3000,
"kms_key_id": "",
"tags": null,
"throughput": 125,
"volume_id": "vol-06b96553464e68c08",
"volume_size": 20,
"volume_type": "gp3"
}
],
"secondary_private_ips": [],
"security_groups": [],
"source_dest_check": true,
"subnet_id": "subnet-07155281789c6d33b",
"tags": {
"Name": "samsung-gauntlet-featurebase-cluster-2",
"Prefix": "samsung-gauntlet",
"Role": "cluster_node"
},
"tags_all": {
"Name": "samsung-gauntlet-featurebase-cluster-2",
"Prefix": "samsung-gauntlet",
"Role": "cluster_node"
},
"tenancy": "default",
"timeouts": null,
"user_data": "ed849ffb2caa5f32ccaf0571e91c3f6d9a54faac",
"user_data_base64": null,
"volume_tags": null,
"vpc_security_group_ids": [
"sg-04d60067fbf393f98"
]
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6MTIwMDAwMDAwMDAwMCwidXBkYXRlIjo2MDAwMDAwMDAwMDB9LCJzY2hlbWFfdmVyc2lvbiI6IjEifQ==",
"dependencies": [
"module.samsung-cluster.aws_iam_instance_profile.fb_cluster_node_profile",
"module.samsung-cluster.aws_key_pair.gitlab-featurebase-ci",
"module.samsung-cluster.aws_security_group.featurebase",
"module.samsung-cluster.data.aws_ami.amazon_linux_2"
]
}
]
},
{
"module": "module.samsung-cluster",
"mode": "managed",
"type": "aws_instance",
"name": "fb_ingest",
"provider": "provider[\"registry.terraform.io/hashicorp/aws\"]",
"instances": [
{
"index_key": 0,
"schema_version": 1,
"attributes": {
"ami": "ami-0b09f36be67d32fff",
"arn": "arn:aws:ec2:us-east-2:977373308795:instance/i-05fe29bb7763ef362",
"associate_public_ip_address": true,
"availability_zone": "us-east-2a",
"capacity_reservation_specification": [
{
"capacity_reservation_preference": "open",
"capacity_reservation_target": []
}
],
"cpu_core_count": 2,
"cpu_threads_per_core": 1,
"credit_specification": [],
"disable_api_termination": false,
"ebs_block_device": [
{
"delete_on_termination": true,
"device_name": "/dev/sdb",
"encrypted": false,
"iops": 10000,
"kms_key_id": "",
"snapshot_id": "",
"tags": {},
"throughput": 125,
"volume_id": "vol-08bc1374e4a0ef2d8",
"volume_size": 100,
"volume_type": "gp3"
}
],
"ebs_optimized": false,
"enclave_options": [
{
"enabled": false
}
],
"ephemeral_block_device": [],
"get_password_data": false,
"hibernation": false,
"host_id": null,
"iam_instance_profile": "samsung-gauntlet-fb_cluster_node_profile",
"id": "i-05fe29bb7763ef362",
"instance_initiated_shutdown_behavior": "stop",
"instance_state": "running",
"instance_type": "m6g.large",
"ipv6_address_count": 0,
"ipv6_addresses": [],
"key_name": "samsung-gauntlet-gitlab-ci",
"launch_template": [],
"metadata_options": [
{
"http_endpoint": "enabled",
"http_put_response_hop_limit": 1,
"http_tokens": "optional"
}
],
"monitoring": true,
"network_interface": [],
"outpost_arn": "",
"password_data": "",
"placement_group": "",
"placement_partition_number": null,
"primary_network_interface_id": "eni-0dac7645cbd9504c0",
"private_dns": "ip-10-0-101-110.us-east-2.compute.internal",
"private_ip": "10.0.101.110",
"public_dns": "",
"public_ip": "3.145.96.245",
"root_block_device": [
{
"delete_on_termination": true,
"device_name": "/dev/xvda",
"encrypted": false,
"iops": 3000,
"kms_key_id": "",
"tags": {},
"throughput": 125,
"volume_id": "vol-054d4f37ba9a40786",
"volume_size": 20,
"volume_type": "gp3"
}
],
"secondary_private_ips": [],
"security_groups": [],
"source_dest_check": true,
"subnet_id": "subnet-066b4b922b54e51a2",
"tags": {
"Name": "samsung-gauntlet-featurebase-ingest-0",
"Prefix": "samsung-gauntlet",
"Role": "ingest_node"
},
"tags_all": {
"Name": "samsung-gauntlet-featurebase-ingest-0",
"Prefix": "samsung-gauntlet",
"Role": "ingest_node"
},
"tenancy": "default",
"timeouts": null,
"user_data": "a511760e647134f82a8c6862bace75462b4be450",
"user_data_base64": null,
"volume_tags": null,
"vpc_security_group_ids": [
"sg-04819516ceb6d6a6d"
]
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6MTIwMDAwMDAwMDAwMCwidXBkYXRlIjo2MDAwMDAwMDAwMDB9LCJzY2hlbWFfdmVyc2lvbiI6IjEifQ==",
"dependencies": [
"module.samsung-cluster.aws_iam_instance_profile.fb_cluster_node_profile",
"module.samsung-cluster.aws_iam_role.fb_cluster_node_role",
"module.samsung-cluster.aws_key_pair.gitlab-featurebase-ci",
"module.samsung-cluster.aws_security_group.ingest",
"module.samsung-cluster.data.aws_ami.amazon_linux_2"
]
}
]
},
{
"module": "module.samsung-cluster",
"mode": "managed",
"type": "aws_key_pair",
"name": "gitlab-featurebase-ci",
"provider": "provider[\"registry.terraform.io/hashicorp/aws\"]",
"instances": [
{
"schema_version": 1,
"attributes": {
"arn": "arn:aws:ec2:us-east-2:977373308795:key-pair/samsung-gauntlet-gitlab-ci",
"fingerprint": "69:e5:4b:15:8d:1f:22:61:de:08:a9:ee:f3:29:5c:69",
"id": "samsung-gauntlet-gitlab-ci",
"key_name": "samsung-gauntlet-gitlab-ci",
"key_name_prefix": "",
"key_pair_id": "key-0f23e421e2db9bc94",
"public_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC91hhpVHNonAG7ku2ugpxEskf9KHeyHJPQJT26OHrMUw7R+T5A8TjqSzTau07sXQ/E9SO3ebV8SJ5PqeaQOnQB8VEvVNK0DjQH7ppvNg1Rfs42FZT9ttzTMvOjsSbK3vZTHXdoKQEdC9NxBwSkFIRGQojK1HUOq9xGrw31fA1OjSwlpLcbx7yyg18lcqW6UOptnVR8U9Yy9qQ5jZF1HtkQ6L9J+gv4o1UyNAUK2bopeGiXpBc3PQ/CFaFT2h/aqLBP66qAHsHVyAFD3PIRtplC5EHa8jXDgLacEls0uF7Q3kRPxvzcuo4g4VkOn1rDy9qH3vd2hT3aKVnM73FIDUiL",
"tags": {},
"tags_all": {}
},
"sensitive_attributes": [],
"private": "eyJzY2hlbWFfdmVyc2lvbiI6IjEifQ=="
}
]
},
{
"module": "module.samsung-cluster",
"mode": "managed",
"type": "aws_security_group",
"name": "featurebase",
"provider": "provider[\"registry.terraform.io/hashicorp/aws\"]",
"instances": [
{
"schema_version": 1,
"attributes": {
"arn": "arn:aws:ec2:us-east-2:977373308795:security-group/sg-04d60067fbf393f98",
"description": "Allow featurebase inbound traffic",
"egress": [
{
"cidr_blocks": [
"0.0.0.0/0"
],
"description": "",
"from_port": 0,
"ipv6_cidr_blocks": [
"::/0"
],
"prefix_list_ids": [],
"protocol": "-1",
"security_groups": [],
"self": false,
"to_port": 0
}
],
"id": "sg-04d60067fbf393f98",
"ingress": [
{
"cidr_blocks": [
"0.0.0.0/0"
],
"description": "SSH",
"from_port": 22,
"ipv6_cidr_blocks": [
"::/0"
],
"prefix_list_ids": [],
"protocol": "tcp",
"security_groups": [],
"self": false,
"to_port": 22
},
{
"cidr_blocks": [
"0.0.0.0/0"
],
"description": "icmp from Anywhere",
"from_port": -1,
"ipv6_cidr_blocks": [],
"prefix_list_ids": [],
"protocol": "icmp",
"security_groups": [],
"self": false,
"to_port": -1
},
{
"cidr_blocks": [
"10.0.0.0/16"
],
"description": "etcd from internal 2",
"from_port": 10401,
"ipv6_cidr_blocks": [],
"prefix_list_ids": [],
"protocol": "tcp",
"security_groups": [],
"self": false,
"to_port": 10401
},
{
"cidr_blocks": [
"10.0.0.0/16"
],
"description": "etcd from internal",
"from_port": 10301,
"ipv6_cidr_blocks": [],
"prefix_list_ids": [],
"protocol": "tcp",
"security_groups": [],
"self": false,
"to_port": 10301
},
{
"cidr_blocks": [
"10.0.0.0/8",
"172.31.0.0/16"
],
"description": "GRPC from Internal",
"from_port": 20101,
"ipv6_cidr_blocks": [],
"prefix_list_ids": [],
"protocol": "tcp",
"security_groups": [],
"self": false,
"to_port": 20101
},
{
"cidr_blocks": [
"10.0.0.0/8",
"172.31.0.0/16"
],
"description": "HTTP from Internal",
"from_port": 10101,
"ipv6_cidr_blocks": [],
"prefix_list_ids": [],
"protocol": "tcp",
"security_groups": [],
"self": false,
"to_port": 10101
},
{
"cidr_blocks": [
"10.0.0.0/8",
"172.31.0.0/16"
],
"description": "PostgreSQL from Internal",
"from_port": 55432,
"ipv6_cidr_blocks": [],
"prefix_list_ids": [],
"protocol": "tcp",
"security_groups": [],
"self": false,
"to_port": 55432
}
],
"name": "samsung-gauntlet-allow_featurebase",
"name_prefix": "",
"owner_id": "977373308795",
"revoke_rules_on_delete": false,
"tags": {
"Name": "allow_featurebase"
},
"tags_all": {
"Name": "allow_featurebase"
},
"timeouts": null,
"vpc_id": "vpc-05a26a122f961dc2b"
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6OTAwMDAwMDAwMDAwfSwic2NoZW1hX3ZlcnNpb24iOiIxIn0="
}
]
},
{
"module": "module.samsung-cluster",
"mode": "managed",
"type": "aws_security_group",
"name": "ingest",
"provider": "provider[\"registry.terraform.io/hashicorp/aws\"]",
"instances": [
{
"schema_version": 1,
"attributes": {
"arn": "arn:aws:ec2:us-east-2:977373308795:security-group/sg-04819516ceb6d6a6d",
"description": "Allow ingest inbound traffic",
"egress": [
{
"cidr_blocks": [
"0.0.0.0/0"
],
"description": "",
"from_port": 0,
"ipv6_cidr_blocks": [
"::/0"
],
"prefix_list_ids": [],
"protocol": "-1",
"security_groups": [],
"self": false,
"to_port": 0
}
],
"id": "sg-04819516ceb6d6a6d",
"ingress": [
{
"cidr_blocks": [
"0.0.0.0/0"
],
"description": "",
"from_port": 10101,
"ipv6_cidr_blocks": [
"::/0"
],
"prefix_list_ids": [],
"protocol": "tcp",
"security_groups": [],
"self": false,
"to_port": 10101
},
{
"cidr_blocks": [
"0.0.0.0/0"
],
"description": "SSH",
"from_port": 22,
"ipv6_cidr_blocks": [
"::/0"
],
"prefix_list_ids": [],
"protocol": "tcp",
"security_groups": [],
"self": false,
"to_port": 22
},
{
"cidr_blocks": [
"0.0.0.0/0"
],
"description": "icmp from Anywhere",
"from_port": -1,
"ipv6_cidr_blocks": [],
"prefix_list_ids": [],
"protocol": "icmp",
"security_groups": [],
"self": false,
"to_port": -1
}
],
"name": "samsung-gauntlet-allow_ingest",
"name_prefix": "",
"owner_id": "977373308795",
"revoke_rules_on_delete": false,
"tags": {
"Name": "allow_ingest"
},
"tags_all": {
"Name": "allow_ingest"
},
"timeouts": null,
"vpc_id": "vpc-05a26a122f961dc2b"
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6OTAwMDAwMDAwMDAwfSwic2NoZW1hX3ZlcnNpb24iOiIxIn0="
}
]
}
]
}