Updating packer builds for new vmdisk-templates storage pool
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
variable "proxmox_host" {
|
||||
type = string
|
||||
default = "proxmox.example.com"
|
||||
}
|
||||
|
||||
variable "proxmox_apiuser" {
|
||||
type = string
|
||||
default = "packer"
|
||||
@@ -8,6 +13,11 @@ variable "proxmox_apitoken" {
|
||||
default = "changeme"
|
||||
}
|
||||
|
||||
variable "proxmox_disk_storage" {
|
||||
type = string
|
||||
default = "packer"
|
||||
}
|
||||
|
||||
source "proxmox-iso" "freebsd-14" {
|
||||
template_name = "freebsd-14"
|
||||
template_description = "FreeBSD 14.3, generated on ${timestamp()}"
|
||||
@@ -24,7 +34,7 @@ source "proxmox-iso" "freebsd-14" {
|
||||
scsi_controller = "virtio-scsi-single"
|
||||
disks {
|
||||
disk_size = "30G"
|
||||
storage_pool = "templates"
|
||||
storage_pool = "${var.proxmox_disk_storage}"
|
||||
type = "scsi"
|
||||
format = "qcow2"
|
||||
}
|
||||
@@ -33,7 +43,7 @@ source "proxmox-iso" "freebsd-14" {
|
||||
model = "virtio"
|
||||
}
|
||||
|
||||
proxmox_url = "https://kamino.int.metaunix.net:8006/api2/json/"
|
||||
proxmox_url = "https://${var.proxmox_host}:8006/api2/json/"
|
||||
insecure_skip_tls_verify = true
|
||||
username = "${var.proxmox_apiuser}"
|
||||
password = "${var.proxmox_apitoken}"
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
variable "proxmox_host" {
|
||||
type = string
|
||||
default = "proxmox.example.com"
|
||||
}
|
||||
|
||||
variable "proxmox_apiuser" {
|
||||
type = string
|
||||
default = "packer"
|
||||
@@ -8,6 +13,11 @@ variable "proxmox_apitoken" {
|
||||
default = "changeme"
|
||||
}
|
||||
|
||||
variable "proxmox_disk_storage" {
|
||||
type = string
|
||||
default = "packer"
|
||||
}
|
||||
|
||||
source "proxmox-iso" "freebsd-15" {
|
||||
template_name = "freebsd-15"
|
||||
template_description = "FreeBSD 15.1, generated on ${timestamp()}"
|
||||
@@ -19,7 +29,7 @@ source "proxmox-iso" "freebsd-15" {
|
||||
"mdmfs -s 100m md /tmp<enter><wait2s>", # mount a writable /tmp memory disk
|
||||
"mdmfs -s 100m md /var/db<enter><wait2s>", # mount a writable /var memory disk
|
||||
"dhclient vtnet0<enter><wait5>", # bring up network
|
||||
"fetch -o /tmp/installerconfig http://{{ .HTTPIP }}:{{ .HTTPPort }}/freebsd-15-installerconfig<enter><wait5s>", # grab the installerconfig
|
||||
"fetch -o /tmp/instaproxmox_hostllerconfig http://{{ .HTTPIP }}:{{ .HTTPPort }}/freebsd-15-installerconfig<enter><wait5s>", # grab the installerconfig
|
||||
"bsdinstall script /tmp/installerconfig<enter>" # execute bsdinstall with fetched config
|
||||
]
|
||||
|
||||
@@ -35,7 +45,7 @@ source "proxmox-iso" "freebsd-15" {
|
||||
scsi_controller = "virtio-scsi-single"
|
||||
disks {
|
||||
disk_size = "30G"
|
||||
storage_pool = "templates"
|
||||
storage_pool = "${var.proxmox_disk_storage}"
|
||||
type = "scsi"
|
||||
format = "qcow2"
|
||||
}
|
||||
@@ -44,7 +54,7 @@ source "proxmox-iso" "freebsd-15" {
|
||||
model = "virtio"
|
||||
}
|
||||
|
||||
proxmox_url = "https://kamino.int.metaunix.net:8006/api2/json/"
|
||||
proxmox_url = "https://${var.proxmox_host}:8006/api2/json/"
|
||||
insecure_skip_tls_verify = true
|
||||
username = "${var.proxmox_apiuser}"
|
||||
password = "${var.proxmox_apitoken}"
|
||||
|
||||
Reference in New Issue
Block a user