DEPRECATED
===

**This repo is no longer maintained. Static IP support exists in [aws-instance](https://git-aws.internal.justin.tv/terraform-modules/aws-instance). Use that.**

Twitch AWS Instance
===

Creates one (or many) AWS instances with the specified role, along with several
convenience resources to go along with it.


Input Variables
---

Pass in a map of subnets to IP you should use for static assigments:

```
variable "private_ip" {
  type = "map"
  default = {
    subnet-ID = "10.x.x.x"
    subnet-ID = "10.x.x.x"
    subnet-ID = "10.x.x.x"
    subnet-ID = "10.x.x.x"
  }
}
```

They should match your subnets in the VPC, look it up or derive. 

Optionally pass in an existing instance_profile if you do not want to automatically create a new porfile.

```instance_profile        = "example-existing-profile"``` 


Created Resources
---

- AWS Instances
- A single instance profile called `<role>-<environment>-profile` that is shared among the instances (unless you override with instance_profile)
- A single IAM Role which is attached to the instance profile (unless you override with instance_profile)
- Internal DNS `A` records pointing to the instances, of the form `<role>-<id>.<env>.<region>.justin.tv`
- Static IP address mapped to each instance (it's up to you to make sure they are available)
