-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvariables.pkr.hcl
163 lines (162 loc) · 4.1 KB
/
variables.pkr.hcl
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
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
variable "enabled_hypervisors" {
type = list(string)
description = "What builders should we use? vbox, vmware, qemu, parallels"
}
variable "keep_vm_artifact" {
type = bool
description = "Keep the resulting VM and do not delete it"
}
variable "host_machine" {
type = object({
is_mac = bool
mac = object({
use_vmnet = bool
})
})
description = "Host information used for configuring hypervisors"
}
variable "vm_filename" {
type = string
description = "The name of the exported VM file without extension"
}
variable "vm_version" {
type = string
description = "The version of the VM (not the OS)"
}
variable "vm_description" {
type = string
description = "The description of the VM"
default = "A base Ubuntu image"
}
variable "vm_os" {
type = object({
name = string
version = string # Semver
arch = string
})
description = "VM Operating System metadata"
}
variable "vm_use_uefi" {
type = bool
description = "Use a UEFI bios"
}
variable "qemu" {
type = object({
firmware = object({
bios = string
uefi = object({
code = string
vars = string
})
})
})
description = "QEMU firmware configuration"
default = {
firmware = {
bios = ""
uefi = {
code = ""
vars = ""
}
}
}
}
variable "virtualbox_guest_additions_version" {
type = string
description = "Version of the Virtualbox Guest Additions to install"
default = ""
}
variable "vm_is_vagrant_box" {
type = bool
description = "The VM will be built into a Vagrant box"
}
variable "vagrant_cloud_access_token" {
type = string
description = "Access token for uploading boxes. Semver. Defaults to env('VAGRANT_CLOUD_TOKEN')"
default = env("VAGRANT_CLOUD_TOKEN")
}
variable "vagrant" {
type = object({
min_version = string
cloud = object({
// E.g. jrichter.io/jammy64
box_tag = string
// Do not upload the box to Vagrant Cloud
skip_upload = bool
// Box version description markdown
version_description = string
})
})
description = "Vagrant and Vagrant Cloud config"
}
variable "hostname" {
type = string
description = "The host's name"
}
variable "hostname_fqdn" {
type = string
description = "The host's fully qualified domain name"
}
variable "system_groups" {
type = map(list(string))
description = "A map of system user groups to create and what users below to what groups"
}
variable "ntp_enabled" {
type = bool
description = "Enable or disable NTP on the system"
}
variable "ssh_enable_password_authentication" {
type = bool
description = "Let's users login over ssh with a password"
}
variable "ssh_delete_host_keys" {
type = bool
description = "Remove any host ssh keys that may have been included in the base image/OS"
}
variable "packages" {
type = object({
essentials = list(string)
extras = list(string)
})
description = "List of packages to install on boot"
}
variable "packages_update" {
type = bool
description = "Update package caches on boot"
}
variable "packages_upgrade" {
type = bool
description = "Upgrate system packages on boot"
}
variable "packages_reboot_if_required" {
type = bool
description = "Reboot if required to after installing or upgrading packages"
}
variable "user_realname" {
type = string
description = "The user's real name"
}
variable "user_name" {
type = string
description = "The user's username"
}
variable "user_password" {
type = string
description = "The user's password"
}
variable "user_password_crypted" {
type = string
description = "The openssl-passwd crypted text password of the user"
}
variable "user_ssh_authorized_key_blobs" {
type = list(string)
description = "Public SSH Keys for the user"
}
variable "user_groups" {
type = list(string)
description = "Groups the user belongs to"
}
variable "user_sudo_config" {
type = string
description = "The user's sudo configuration (without the leading username)"
}