forked from fvumbaca/terraform-proxmox-k3s
-
Notifications
You must be signed in to change notification settings - Fork 2
/
variables.tf
122 lines (115 loc) · 3.88 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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
variable "proxmox" {
type = object({
endpoint = string,
api_token = string
})
}
variable "image" {
type = object({
download_type = optional(string, "local"),
path = optional(string, "http://boot.at.home/cloudimages/jammy-server-cloudimg-amd64.img")
datastore_id = optional(string, "iso")
})
}
variable "cluster" {
type = object({
name = string,
target_node = string,
master_nodes_count = number,
api_hostnames = optional(list(string), []),
k3s_disable_components = optional(list(string), []),
http_proxy = optional(string, ""),
insecure_registries = optional(list(string), []),
ssh_key_path = optional(string),
cloud_config_datastore_id = optional(string, "local")
})
}
variable "default_node_settings" {
type = object({
vm_id = optional(number),
cores = optional(number, 2),
sockets = optional(number, 1),
storage_id = string,
memory = number,
disk_size = number,
nameserver = string,
searchdomain = string,
domain = string,
network_bridge = optional(string, "vmbr0"),
network_tag = optional(number),
subnet = string,
gw = string,
node = optional(string),
pool = optional(string, "local-lvm")
onboot = optional(bool),
boot = optional(string, "order=virtio0")
})
}
variable "support_node_settings" {
type = object({
vm_id = optional(number),
cores = optional(number),
db_name = optional(string, "k3s"),
db_user = optional(string, "k3s"),
domain = optional(string),
gw = optional(string),
subnet = optional(string),
ip_offset = optional(number),
memory = optional(number),
disk_size = optional(number),
network_bridge = optional(string),
network_tag = optional(number),
sockets = optional(number),
storage_id = optional(string),
node = optional(string),
pool = optional(string),
onboot = optional(bool),
boot = optional(string)
})
}
variable "master_node_settings" {
type = object({
vm_id = optional(number),
cores = optional(number),
domain = optional(string),
gw = optional(string),
subnet = optional(string),
ip_offset = optional(number),
memory = optional(number),
disk_size = optional(number),
network_bridge = optional(string),
network_tag = optional(number),
sockets = optional(number),
storage_id = optional(string),
node = optional(string),
pool = optional(string),
onboot = optional(bool),
boot = optional(string),
node_labels = optional(list(string))
})
}
variable "node_pools" {
description = "Node pool definitions for the cluster."
type = list(object({
name = string,
size = number,
vm_id = optional(number),
taints = optional(list(string)),
cores = optional(number),
domain = optional(string),
gw = optional(string),
subnet = optional(string),
ip_offset = optional(number),
memory = optional(number),
disk_size = optional(number),
network_bridge = optional(string),
network_tag = optional(number),
sockets = optional(number),
storage_id = optional(string),
node = optional(string),
pool = optional(string),
onboot = optional(bool),
boot = optional(string),
node_labels = optional(list(string))
}))
}