Commit ae35e86a authored by Cameron McFarland's avatar Cameron McFarland

Ran tf fmt

parent c5da8b77
...@@ -14,7 +14,8 @@ resource "aws_iam_policy" "snowplow_collector_policy" { ...@@ -14,7 +14,8 @@ resource "aws_iam_policy" "snowplow_collector_policy" {
description = "Policy the allows the collector to access other AWS services such as Kinesis." description = "Policy the allows the collector to access other AWS services such as Kinesis."
name = "snowplow-collector-policy" name = "snowplow-collector-policy"
path = "/" path = "/"
policy = <<EOF
policy = <<EOF
{ {
"Version": "2012-10-17", "Version": "2012-10-17",
"Statement": [ "Statement": [
...@@ -44,10 +45,11 @@ EOF ...@@ -44,10 +45,11 @@ EOF
} }
resource "aws_iam_policy" "snowplow_enricher_policy" { resource "aws_iam_policy" "snowplow_enricher_policy" {
description = "" description = ""
name = "snowplow-enricher-policy" name = "snowplow-enricher-policy"
path = "/" path = "/"
policy = <<EOF
policy = <<EOF
{ {
"Version": "2012-10-17", "Version": "2012-10-17",
"Statement": [ "Statement": [
...@@ -87,10 +89,11 @@ EOF ...@@ -87,10 +89,11 @@ EOF
} }
resource "aws_iam_policy" "snowplow_s3loader_policy" { resource "aws_iam_policy" "snowplow_s3loader_policy" {
description = "Policy to provide AWS access to snowplow s3loader instances such as S3, DynamoDB, and Kinesis." description = "Policy to provide AWS access to snowplow s3loader instances such as S3, DynamoDB, and Kinesis."
name = "snowplow-s3loader-policy" name = "snowplow-s3loader-policy"
path = "/" path = "/"
policy = <<EOF
policy = <<EOF
{ {
"Version": "2012-10-17", "Version": "2012-10-17",
"Statement": [ "Statement": [
...@@ -141,40 +144,44 @@ EOF ...@@ -141,40 +144,44 @@ EOF
// VPC // VPC
resource "aws_vpc" "snowplow_vpc" { resource "aws_vpc" "snowplow_vpc" {
cidr_block = "10.32.0.0/16" cidr_block = "10.32.0.0/16"
tags = { tags = {
Name = "SnowPlow VPC" Name = "SnowPlow VPC"
environment = "SnowPlow" environment = "SnowPlow"
} }
} }
// Subnet // Subnet
resource "aws_subnet" "snowplow_subnet_1" { resource "aws_subnet" "snowplow_subnet_1" {
vpc_id = "${aws_vpc.snowplow_vpc.id}" vpc_id = "${aws_vpc.snowplow_vpc.id}"
cidr_block = "10.32.2.0/24" cidr_block = "10.32.2.0/24"
availability_zone = "us-east-1a" availability_zone = "us-east-1a"
tags = { tags = {
Name = "SnowPlow Subnet 1" Name = "SnowPlow Subnet 1"
environment = "SnowPlow" environment = "SnowPlow"
} }
} }
resource "aws_subnet" "snowplow_subnet_2" { resource "aws_subnet" "snowplow_subnet_2" {
vpc_id = "${aws_vpc.snowplow_vpc.id}" vpc_id = "${aws_vpc.snowplow_vpc.id}"
cidr_block = "10.32.1.0/24" cidr_block = "10.32.1.0/24"
availability_zone = "us-east-1e" availability_zone = "us-east-1e"
tags = { tags = {
Name = "SnowPlow Subnet 2" Name = "SnowPlow Subnet 2"
environment = "SnowPlow" environment = "SnowPlow"
} }
} }
resource "aws_subnet" "snowplow_subnet_3" { resource "aws_subnet" "snowplow_subnet_3" {
vpc_id = "${aws_vpc.snowplow_vpc.id}" vpc_id = "${aws_vpc.snowplow_vpc.id}"
cidr_block = "10.32.0.0/24" cidr_block = "10.32.0.0/24"
availability_zone = "us-east-1b" availability_zone = "us-east-1b"
tags = { tags = {
Name = "SnowPlow Subnet 3" Name = "SnowPlow Subnet 3"
environment = "SnowPlow" environment = "SnowPlow"
} }
} }
...@@ -184,7 +191,7 @@ resource "aws_internet_gateway" "snowplow_gw" { ...@@ -184,7 +191,7 @@ resource "aws_internet_gateway" "snowplow_gw" {
vpc_id = "${aws_vpc.snowplow_vpc.id}" vpc_id = "${aws_vpc.snowplow_vpc.id}"
tags = { tags = {
Name = "SnowPlow Gateway" Name = "SnowPlow Gateway"
environment = "SnowPlow" environment = "SnowPlow"
} }
} }
...@@ -194,7 +201,7 @@ resource "aws_route_table" "snowplow_route_table" { ...@@ -194,7 +201,7 @@ resource "aws_route_table" "snowplow_route_table" {
vpc_id = "${aws_vpc.snowplow_vpc.id}" vpc_id = "${aws_vpc.snowplow_vpc.id}"
tags = { tags = {
Name = "SnowPlow Routing Table" Name = "SnowPlow Routing Table"
environment = "SnowPlow" environment = "SnowPlow"
} }
} }
...@@ -205,9 +212,9 @@ resource "aws_main_route_table_association" "snowplow_main_route_table_associati ...@@ -205,9 +212,9 @@ resource "aws_main_route_table_association" "snowplow_main_route_table_associati
} }
resource "aws_route" "snowplow_route" { resource "aws_route" "snowplow_route" {
route_table_id = "${aws_route_table.snowplow_route_table.id}" route_table_id = "${aws_route_table.snowplow_route_table.id}"
destination_cidr_block = "0.0.0.0/0" destination_cidr_block = "0.0.0.0/0"
gateway_id = "${aws_internet_gateway.snowplow_gw.id}" gateway_id = "${aws_internet_gateway.snowplow_gw.id}"
} }
resource "aws_route_table_association" "snowplow_route_table_association_1" { resource "aws_route_table_association" "snowplow_route_table_association_1" {
...@@ -230,6 +237,7 @@ resource "aws_kinesis_stream" "snowplow_raw_good" { ...@@ -230,6 +237,7 @@ resource "aws_kinesis_stream" "snowplow_raw_good" {
name = "snowplow-raw-good" name = "snowplow-raw-good"
shard_count = 1 shard_count = 1
retention_period = 48 retention_period = 48
shard_level_metrics = [ shard_level_metrics = [
"IncomingBytes", "IncomingBytes",
"OutgoingBytes", "OutgoingBytes",
...@@ -244,6 +252,7 @@ resource "aws_kinesis_stream" "snowplow_raw_bad" { ...@@ -244,6 +252,7 @@ resource "aws_kinesis_stream" "snowplow_raw_bad" {
name = "snowplow-raw-bad" name = "snowplow-raw-bad"
shard_count = 1 shard_count = 1
retention_period = 48 retention_period = 48
shard_level_metrics = [ shard_level_metrics = [
"IncomingBytes", "IncomingBytes",
"OutgoingBytes", "OutgoingBytes",
...@@ -258,6 +267,7 @@ resource "aws_kinesis_stream" "snowplow_enriched_bad" { ...@@ -258,6 +267,7 @@ resource "aws_kinesis_stream" "snowplow_enriched_bad" {
name = "snowplow-enriched-bad" name = "snowplow-enriched-bad"
shard_count = 1 shard_count = 1
retention_period = 48 retention_period = 48
shard_level_metrics = [ shard_level_metrics = [
"IncomingBytes", "IncomingBytes",
"OutgoingBytes", "OutgoingBytes",
...@@ -272,6 +282,7 @@ resource "aws_kinesis_stream" "snowplow_enriched_good" { ...@@ -272,6 +282,7 @@ resource "aws_kinesis_stream" "snowplow_enriched_good" {
name = "snowplow-enriched-good" name = "snowplow-enriched-good"
shard_count = 1 shard_count = 1
retention_period = 48 retention_period = 48
shard_level_metrics = [ shard_level_metrics = [
"IncomingBytes", "IncomingBytes",
"OutgoingBytes", "OutgoingBytes",
...@@ -286,6 +297,7 @@ resource "aws_kinesis_stream" "snowplow_s3loader_bad" { ...@@ -286,6 +297,7 @@ resource "aws_kinesis_stream" "snowplow_s3loader_bad" {
name = "snowplow-s3loader-bad" name = "snowplow-s3loader-bad"
shard_count = 1 shard_count = 1
retention_period = 48 retention_period = 48
shard_level_metrics = [ shard_level_metrics = [
"IncomingBytes", "IncomingBytes",
"OutgoingBytes", "OutgoingBytes",
......
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