Fix Pimox template replacement lifecycle
This commit is contained in:
parent
d90ffe5b14
commit
92e5976f1d
|
|
@ -133,7 +133,6 @@ resource "null_resource" "pimox_template_vm_create" {
|
|||
net0 = local.pimox_template_net0
|
||||
scsi0 = var.pimox_template_scsi0
|
||||
efidisk0 = var.pimox_template_efidisk0
|
||||
replace_existing = tostring(var.pimox_template_replace_existing)
|
||||
}
|
||||
|
||||
connection {
|
||||
|
|
@ -149,7 +148,7 @@ resource "null_resource" "pimox_template_vm_create" {
|
|||
set -eu
|
||||
|
||||
vmid="${self.triggers.vmid}"
|
||||
replace_existing="${self.triggers.replace_existing}"
|
||||
replace_existing="${var.pimox_template_replace_existing}"
|
||||
qm_cmd="${self.triggers.qm_bin}"
|
||||
|
||||
if [ ! -x "$qm_cmd" ]; then
|
||||
|
|
@ -233,6 +232,7 @@ resource "null_resource" "pimox_template_vm_seal" {
|
|||
guest_user = var.pimox_template_build_user
|
||||
guest_key_path = var.pimox_template_build_ssh_key_path
|
||||
seal_version = "5"
|
||||
create_id = null_resource.pimox_template_vm_create[0].id
|
||||
config_hash = local.config_hash
|
||||
timeout = var.pimox_template_build_timeout
|
||||
timeout_seconds = tostring(var.pimox_template_build_timeout_seconds)
|
||||
|
|
|
|||
Loading…
Reference in New Issue