2023-12-15 04:36:58 -05:00
# Variables common to all CSPs
variable " name " {
type = string
default = " constell "
description = " Base name of the cluster. "
}
2023-07-03 10:33:00 -04:00
variable " node_groups " {
type = map ( object ( {
role = string
initial_count = number // number of instances in the node group
2023-08-02 04:39:18 -04:00
flavor_id = string // flavor (machine type) to use for instances
2023-07-03 10:33:00 -04:00
state_disk_size = number // size of state disk (GiB)
state_disk_type = string // type of state disk. Can be 'standard' or 'premium'
zone = string // availability zone
} ) )
validation {
condition = can ( [ for group in var . node_groups : group . role == " control-plane " | | group . role == " worker " ] )
error_message = " The role has to be 'control-plane' or 'worker'. "
}
description = " A map of node group names to node group configurations. "
}
2023-12-15 04:36:58 -05:00
variable " image_id " {
2023-02-27 12:19:52 -05:00
type = string
2023-12-15 04:36:58 -05:00
description = " OS image URL for the cluster's nodes. "
2023-02-27 12:19:52 -05:00
}
2023-12-15 04:36:58 -05:00
variable " debug " {
type = bool
default = false
description = " DO NOT USE IN PRODUCTION. Enable debug mode. This opens up a debugd port that can be used to deploy a custom bootstrapper. "
}
variable " custom_endpoint " {
2023-02-27 12:19:52 -05:00
type = string
2023-12-15 04:36:58 -05:00
default = " "
description = " Custom endpoint to use for the Kubernetes API server. If not set, the default endpoint will be used. "
2023-02-27 12:19:52 -05:00
}
2023-12-15 04:36:58 -05:00
# OpenStack-specific variables
variable " cloud " {
2023-02-27 12:19:52 -05:00
type = string
2023-12-15 04:36:58 -05:00
default = null
description = " Cloud to use within the OpenStack \ " clouds . yaml \ " file. Optional. If not set, environment variables are used. "
2023-02-27 12:19:52 -05:00
}
variable " direct_download " {
type = bool
2023-12-15 04:36:58 -05:00
description = " Download OS image directly from source URL to OpenStack. Otherwise, the image is downloaded to the local machine and uploads to OpenStack. "
2023-02-27 12:19:52 -05:00
}
variable " floating_ip_pool_id " {
type = string
2023-12-15 04:36:58 -05:00
description = " Pool (network name) to use for floating IPs. "
2023-02-27 12:19:52 -05:00
}
2023-03-03 09:28:28 -05:00
variable " openstack_user_domain_name " {
2023-03-03 04:10:36 -05:00
type = string
2023-03-03 09:28:28 -05:00
description = " OpenStack user domain name. "
2023-03-03 04:10:36 -05:00
}
2023-03-03 09:28:28 -05:00
variable " openstack_username " {
type = string
description = " OpenStack user name. "
}
variable " openstack_password " {
type = string
description = " OpenStack password. "
}