flavien
bceb41d08d
continuous-integration/drone/push Build is passing
Details
Reviewed-on: #1 |
||
---|---|---|
.drone.yml | ||
.gitignore | ||
.pre-commit-config.yaml | ||
.releaserc.json | ||
README.md | ||
main.tf | ||
outputs.tf | ||
variables.tf |
README.md
aws_servers terraform module
Terraform module to provision servers.
Provision servers in private and public subnets.
Instances are launched by auto scaling groups and an elastic load balancer is provisioned for public instances.
Instances are tagged with key "Tier" and value "public" or "private".
The IP used during a deployment is authorized to ssh in public instances.
To create the networks use: aws_network_module
To alias the elastic load balancer to domain use: aws_elb_alias_module
Requirements
No requirements.
Providers
Name | Version |
---|---|
aws | n/a |
http | n/a |
Modules
No modules.
Resources
Name | Type |
---|---|
aws_autoscaling_group.private | resource |
aws_autoscaling_group.public | resource |
aws_elb.public | resource |
aws_launch_configuration.private | resource |
aws_launch_configuration.public | resource |
aws_security_group.private | resource |
aws_security_group.public | resource |
aws_instances.private | data source |
aws_instances.public | data source |
aws_vpc.selected | data source |
http_http.myip | data source |
Inputs
Name | Description | Type | Default | Required |
---|---|---|---|---|
env | Environment of the deployment | string |
n/a | yes |
image_id | Id of the image to provision | string |
n/a | yes |
key_name | Name of the ssh key pair to provision | string |
n/a | yes |
private_instances_count | Number of private instances to provision | number |
3 |
no |
private_instances_user_data | User data to provision for private instances | string |
n/a | yes |
private_subnets_ids | Ids of the private subnets | list(string) |
n/a | yes |
public_instances_count | Number of public instances to provision | number |
3 |
no |
public_instances_user_data | User data to provision for public instances | string |
n/a | yes |
public_subnets_ids | Ids of the public subnets | list(string) |
n/a | yes |
tags | General tags to apply to all the resources | map(string) |
{} |
no |
vpc_id | Id of the VPC on which to deploy | string |
n/a | yes |
Outputs
Name | Description |
---|---|
elb_dns_name | Dns name of the public ELB |
private_instances_private_ips | Private instances ip addresses |
public_instances_public_ips | Public instances ip addresses |