Commit 996fac24 authored by Cameron McFarland's avatar Cameron McFarland

Added some more resources and notes in the README.

parent 760845b9
Locally pull down the docker images we think we'll need.
* docker pull snowplow-docker-registry.bintray.io/snowplow/scala-stream-collector-kinesis:0.15.0
* docker pull snowplow-docker-registry.bintray.io/snowplow/stream-enrich-kinesis:0.21:0
Need to tag them and put them into the two ECR repositories.
Need to build a VPC for this entire thing. 10.32.0.0/16
There is also a subnet.
ECS Tasks need a IAM role to allow access to things?
Volumes and config?
One way is to include the config into the docker image. Not easy to update configs.
Mount an EBS volume? Not sure how this works yet.
The default config (of which there isn't one in the pre-built images) does not support env variables.
......@@ -9,9 +9,36 @@ provider "aws" {
version = "~> 1.41"
}
// ECR Repository
resource "aws_ecr_repository" "snowplow_ecr_repository" {
name = "SnowPlow"
// VPC
resource "aws_vpc" "snowplow_vpc" {
cidr_block = "10.32.0.0/16"
tags = {
Name = "SnowPlow VPC"
environment = "SnowPlow"
}
}
// Subnet
resource "aws_subnet" "snowplow_subnet" {
vpc_id = "${aws_vpc.snowplow_vpc.id}"
cidr_block = "10.32.0.0/24"
tags = {
Name = "SnowPlow Subnet"
environment = "SnowPlow"
}
}
// ECR SnowPlow Collector Repository
resource "aws_ecr_repository" "snowplow_ecr_collector_repo" {
name = "SnowPlow Collector"
tags = {
environment = "SnowPlow"
}
}
resource "aws_ecr_repository" "snowplow_ecr_enricher_repo" {
name = "SnowPlow Enricher"
tags = {
environment = "SnowPlow"
}
......@@ -24,3 +51,34 @@ resource "aws_ecs_cluster" "snowplow_ecs_cluster" {
environment = "SnowPlow"
}
}
// Kinesis Streams
resource "aws_kinesis_stream" "snowplow_good_stream" {
name = "SnowPlow-Good-Stream"
shard_count = 1
retention_period = 48
shard_level_metrics = [
"IncomingBytes",
"OutgoingBytes",
]
tags = {
environment = "SnowPlow"
}
}
resource "aws_kinesis_stream" "snowplow_bad_stream" {
name = "SnowPlow-Bad-Stream"
shard_count = 1
retention_period = 48
shard_level_metrics = [
"IncomingBytes",
"OutgoingBytes",
]
tags = {
environment = "SnowPlow"
}
}
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