-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathvariables.tf
100 lines (85 loc) · 2.4 KB
/
variables.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
### Basic config
variable "name" {
description = "the name of the deployment. This is used to distinguish resources"
}
variable "ssh_public_keystrings" {
type = "list"
description = "public ssh keys for docker user"
}
variable "region" {
description = "aws region"
default = "eu-west-1"
}
### Network configuration ###
variable "public_access_addresses" {
type = "list"
description = "The list of ip addresses that can connect to the swarm cluster. This is used for deployments"
}
variable "vpc_cidr_block" {
description = "the cidr block for the vpc"
default = "10.0.0.0/16"
}
variable "vpc_azs" {
type = "list"
description = "the list of the aws availability zones"
default = ["eu-west-1a", "eu-west-1b"]
}
variable "public_subnets" {
type = "list"
description = "the list of public subnets to be deployed. This is where the initial swarm manager will be deployed"
default = ["10.0.101.0/24", "10.0.102.0/24"]
}
variable "private_subnets" {
type = "list"
description = "the list of private subnets to be deployed. This is where the swarm workers will be deployed"
default = ["10.0.1.0/24", "10.0.2.0/24"]
}
variable "enable_s3_endpoint" {
description = "whether we should enable the s3 endpoint in the vpc"
default = true
}
### Instance configuration ###
variable "manager_instance_size" {
description = "the instance size of the swarm manager"
default = "t2.micro"
}
variable "worker_instance_size" {
description = "the instance size of the swarm worker"
default = "t2.micro"
}
variable "additional_manager_count" {
description = "the number of additional manager instances to launch"
default = 1
}
variable "worker_min_asg_size" {
description = "The minimal number of worker nodes in the swarm cluster"
default = 0
}
variable "worker_max_asg_size" {
description = "The maximum number of worker nodes in the swarm cluster"
default = 1
}
variable "worker_desired_asg_size" {
description = "The maximum number of worker nodes in the swarm cluster"
default = 1
}
### ELB configuration ###
# Listener
variable "listener" {
description = "A list of listener blocks"
type = "list"
default = [
{
instance_port = "443"
instance_protocol = "TCP"
lb_port = "443"
lb_protocol = "TCP"
},
]
}
# Access logs
variable "access_logs" {
description = "An access logs block"
type = "list"
default = []
}