2016-06-06 04:52:20 +08:00
|
|
|
variable "cluster_name" {
|
|
|
|
default = "example"
|
|
|
|
}
|
|
|
|
|
2018-07-31 17:18:27 +08:00
|
|
|
variable "az_list" {
|
2020-02-18 20:29:27 +08:00
|
|
|
description = "List of Availability Zones to use for masters in your OpenStack cluster"
|
|
|
|
type = list(string)
|
|
|
|
default = ["nova"]
|
|
|
|
}
|
|
|
|
|
|
|
|
variable "az_list_node" {
|
|
|
|
description = "List of Availability Zones to use for nodes in your OpenStack cluster"
|
|
|
|
type = list(string)
|
2019-02-18 13:04:41 +08:00
|
|
|
default = ["nova"]
|
2018-07-31 17:18:27 +08:00
|
|
|
}
|
|
|
|
|
2017-12-05 20:48:47 +08:00
|
|
|
variable "number_of_bastions" {
|
|
|
|
default = 1
|
|
|
|
}
|
|
|
|
|
2016-06-06 04:52:20 +08:00
|
|
|
variable "number_of_k8s_masters" {
|
|
|
|
default = 2
|
|
|
|
}
|
|
|
|
|
2017-09-27 17:59:09 +08:00
|
|
|
variable "number_of_k8s_masters_no_etcd" {
|
|
|
|
default = 2
|
|
|
|
}
|
|
|
|
|
|
|
|
variable "number_of_etcd" {
|
|
|
|
default = 2
|
|
|
|
}
|
|
|
|
|
2016-10-26 22:56:15 +08:00
|
|
|
variable "number_of_k8s_masters_no_floating_ip" {
|
|
|
|
default = 2
|
|
|
|
}
|
|
|
|
|
2017-09-27 17:59:09 +08:00
|
|
|
variable "number_of_k8s_masters_no_floating_ip_no_etcd" {
|
|
|
|
default = 2
|
|
|
|
}
|
|
|
|
|
2016-06-06 04:52:20 +08:00
|
|
|
variable "number_of_k8s_nodes" {
|
|
|
|
default = 1
|
|
|
|
}
|
|
|
|
|
2016-10-26 22:56:15 +08:00
|
|
|
variable "number_of_k8s_nodes_no_floating_ip" {
|
|
|
|
default = 1
|
|
|
|
}
|
|
|
|
|
2016-11-11 11:59:46 +08:00
|
|
|
variable "number_of_gfs_nodes_no_floating_ip" {
|
|
|
|
default = 0
|
|
|
|
}
|
|
|
|
|
2019-09-25 20:17:59 +08:00
|
|
|
variable "bastion_root_volume_size_in_gb" {
|
|
|
|
default = 0
|
|
|
|
}
|
|
|
|
|
|
|
|
variable "etcd_root_volume_size_in_gb" {
|
|
|
|
default = 0
|
|
|
|
}
|
|
|
|
|
|
|
|
variable "master_root_volume_size_in_gb" {
|
|
|
|
default = 0
|
|
|
|
}
|
|
|
|
|
|
|
|
variable "node_root_volume_size_in_gb" {
|
|
|
|
default = 0
|
|
|
|
}
|
|
|
|
|
|
|
|
variable "gfs_root_volume_size_in_gb" {
|
|
|
|
default = 0
|
|
|
|
}
|
|
|
|
|
2016-11-11 11:59:46 +08:00
|
|
|
variable "gfs_volume_size_in_gb" {
|
|
|
|
default = 75
|
|
|
|
}
|
|
|
|
|
2016-06-06 04:52:20 +08:00
|
|
|
variable "public_key_path" {
|
|
|
|
description = "The path of the ssh pub key"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = "~/.ssh/id_rsa.pub"
|
2016-06-06 04:52:20 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
variable "image" {
|
|
|
|
description = "the image to use"
|
2019-09-25 20:17:59 +08:00
|
|
|
default = ""
|
2016-06-06 04:52:20 +08:00
|
|
|
}
|
|
|
|
|
2016-11-11 11:59:46 +08:00
|
|
|
variable "image_gfs" {
|
|
|
|
description = "Glance image to use for GlusterFS"
|
2019-09-25 20:17:59 +08:00
|
|
|
default = ""
|
2016-11-11 11:59:46 +08:00
|
|
|
}
|
|
|
|
|
2016-06-06 04:52:20 +08:00
|
|
|
variable "ssh_user" {
|
|
|
|
description = "used to fill out tags for ansible inventory"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = "ubuntu"
|
2016-06-06 04:52:20 +08:00
|
|
|
}
|
|
|
|
|
2016-11-11 11:59:46 +08:00
|
|
|
variable "ssh_user_gfs" {
|
|
|
|
description = "used to fill out tags for ansible inventory"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = "ubuntu"
|
2016-11-11 11:59:46 +08:00
|
|
|
}
|
|
|
|
|
2017-12-05 20:48:47 +08:00
|
|
|
variable "flavor_bastion" {
|
2019-02-26 12:13:16 +08:00
|
|
|
description = "Use 'openstack flavor list' command to see what your OpenStack instance uses for IDs"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = 3
|
2017-12-05 20:48:47 +08:00
|
|
|
}
|
|
|
|
|
2016-06-06 04:52:20 +08:00
|
|
|
variable "flavor_k8s_master" {
|
2019-02-26 12:13:16 +08:00
|
|
|
description = "Use 'openstack flavor list' command to see what your OpenStack instance uses for IDs"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = 3
|
2016-06-06 04:52:20 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
variable "flavor_k8s_node" {
|
2019-02-26 12:13:16 +08:00
|
|
|
description = "Use 'openstack flavor list' command to see what your OpenStack instance uses for IDs"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = 3
|
2016-06-06 04:52:20 +08:00
|
|
|
}
|
|
|
|
|
2017-09-27 17:59:09 +08:00
|
|
|
variable "flavor_etcd" {
|
2019-02-26 12:13:16 +08:00
|
|
|
description = "Use 'openstack flavor list' command to see what your OpenStack instance uses for IDs"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = 3
|
2017-09-27 17:59:09 +08:00
|
|
|
}
|
|
|
|
|
2016-11-11 11:59:46 +08:00
|
|
|
variable "flavor_gfs_node" {
|
2019-02-26 12:13:16 +08:00
|
|
|
description = "Use 'openstack flavor list' command to see what your OpenStack instance uses for IDs"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = 3
|
2016-11-11 11:59:46 +08:00
|
|
|
}
|
2016-06-06 04:52:20 +08:00
|
|
|
|
|
|
|
variable "network_name" {
|
|
|
|
description = "name of the internal network to use"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = "internal"
|
2016-06-06 04:52:20 +08:00
|
|
|
}
|
|
|
|
|
2019-08-21 20:09:15 +08:00
|
|
|
variable "network_dns_domain" {
|
|
|
|
description = "dns_domain for the internal network"
|
|
|
|
type = "string"
|
|
|
|
default = null
|
|
|
|
}
|
|
|
|
|
2018-10-19 18:39:34 +08:00
|
|
|
variable "use_neutron" {
|
|
|
|
description = "Use neutron"
|
|
|
|
default = 1
|
|
|
|
}
|
|
|
|
|
2018-06-15 01:31:04 +08:00
|
|
|
variable "subnet_cidr" {
|
|
|
|
description = "Subnet CIDR block."
|
2019-02-18 13:04:41 +08:00
|
|
|
type = "string"
|
|
|
|
default = "10.0.0.0/24"
|
2018-06-15 01:31:04 +08:00
|
|
|
}
|
|
|
|
|
2018-01-05 19:09:04 +08:00
|
|
|
variable "dns_nameservers" {
|
2017-12-05 20:48:47 +08:00
|
|
|
description = "An array of DNS name server names used by hosts in this subnet."
|
2018-01-05 19:09:04 +08:00
|
|
|
type = "list"
|
|
|
|
default = []
|
2017-12-05 20:48:47 +08:00
|
|
|
}
|
|
|
|
|
2016-06-06 04:52:20 +08:00
|
|
|
variable "floatingip_pool" {
|
|
|
|
description = "name of the floating ip pool to use"
|
2018-01-05 19:09:04 +08:00
|
|
|
default = "external"
|
2016-06-06 04:52:20 +08:00
|
|
|
}
|
|
|
|
|
2019-05-09 17:16:50 +08:00
|
|
|
variable "wait_for_floatingip" {
|
|
|
|
description = "Terraform will poll the instance until the floating IP has been associated."
|
|
|
|
default = "false"
|
|
|
|
}
|
|
|
|
|
2017-12-05 20:48:47 +08:00
|
|
|
variable "external_net" {
|
|
|
|
description = "uuid of the external/public network"
|
|
|
|
}
|
2018-04-30 23:11:07 +08:00
|
|
|
|
|
|
|
variable "supplementary_master_groups" {
|
|
|
|
description = "supplementary kubespray ansible groups for masters, such kube-node"
|
2019-02-18 13:04:41 +08:00
|
|
|
default = ""
|
2018-04-30 23:11:07 +08:00
|
|
|
}
|
2018-06-28 22:32:59 +08:00
|
|
|
|
|
|
|
variable "supplementary_node_groups" {
|
|
|
|
description = "supplementary kubespray ansible groups for worker nodes, such as kube-ingress"
|
2019-02-18 13:04:41 +08:00
|
|
|
default = ""
|
2018-06-28 22:32:59 +08:00
|
|
|
}
|
2018-09-28 17:35:02 +08:00
|
|
|
|
|
|
|
variable "bastion_allowed_remote_ips" {
|
|
|
|
description = "An array of CIDRs allowed to SSH to hosts"
|
2019-02-18 13:04:41 +08:00
|
|
|
type = "list"
|
|
|
|
default = ["0.0.0.0/0"]
|
2018-09-28 17:35:02 +08:00
|
|
|
}
|
2018-10-31 19:09:22 +08:00
|
|
|
|
2019-04-21 16:57:44 +08:00
|
|
|
variable "master_allowed_remote_ips" {
|
|
|
|
description = "An array of CIDRs allowed to access API of masters"
|
|
|
|
type = "list"
|
|
|
|
default = ["0.0.0.0/0"]
|
|
|
|
}
|
|
|
|
|
2019-04-15 22:22:08 +08:00
|
|
|
variable "k8s_allowed_remote_ips" {
|
|
|
|
description = "An array of CIDRs allowed to SSH to hosts"
|
|
|
|
type = "list"
|
|
|
|
default = []
|
|
|
|
}
|
|
|
|
|
2019-04-17 17:10:03 +08:00
|
|
|
variable "k8s_allowed_egress_ips" {
|
|
|
|
description = "An array of CIDRs allowed for egress traffic"
|
|
|
|
type = "list"
|
|
|
|
default = ["0.0.0.0/0"]
|
|
|
|
}
|
|
|
|
|
2018-10-31 19:09:22 +08:00
|
|
|
variable "worker_allowed_ports" {
|
|
|
|
type = "list"
|
2019-02-18 13:04:41 +08:00
|
|
|
|
2018-10-31 19:09:22 +08:00
|
|
|
default = [
|
|
|
|
{
|
2019-02-18 13:04:41 +08:00
|
|
|
"protocol" = "tcp"
|
|
|
|
"port_range_min" = 30000
|
|
|
|
"port_range_max" = 32767
|
2018-10-31 19:09:22 +08:00
|
|
|
"remote_ip_prefix" = "0.0.0.0/0"
|
2019-02-18 13:04:41 +08:00
|
|
|
},
|
2018-10-31 19:09:22 +08:00
|
|
|
]
|
|
|
|
}
|
2019-10-07 19:09:09 +08:00
|
|
|
|
|
|
|
variable "use_access_ip" {
|
|
|
|
default = 1
|
|
|
|
}
|
2019-12-09 17:15:10 +08:00
|
|
|
|
|
|
|
variable "use_server_groups" {
|
|
|
|
default = false
|
2020-02-18 20:29:27 +08:00
|
|
|
}
|