Closed maksimsamt closed 1 month ago
This is definitely an SDK issue.
This is definitely an SDK issue.
@Tinyblargon, please translate this :) How can be solved this issue?
@maksimsamt The Terraform project doesn't directly communicate with the PVE API. It uses the Proxmox-SDK then the SDK connects to PVE. The SDK takes care of all the weird quirks of the PVE API. So, the Terraform project only has the simple code.
So data gets transformed twice: Terraform -> SDK -> PVE
Please tell me if something is still unclear.
@maksimsamt The Terraform project doesn't directly communicate with the PVE API. It uses the Proxmox-SDK then the SDK connects to PVE. The SDK takes care of all the weird quirks of the PVE API. So, the Terraform project only has the simple code.
So data gets transformed twice: Terraform -> SDK -> PVE
Please tell me if something is still unclear.
@Tinyblargon , Thank you very much for your clear explanation, now there are no questions at this point.
Just a question, will you address this issue to the corresponding SDK project yourself?
@maksimsamt I'm also the maintainer of the SDK project, yes. So, at some point I will.
@Tinyblargon,
Most likely this is a directly related problem.
Noticed that creating VM from scratch with disabled ballooning device (e.g. balloon = 0
), provider ignores this and enable ballooning device:
...
resource "proxmox_vm_qemu" "cloud_vm_from_packer_template" {
...
memory = 4096
balloon = 0
...
}
...
That is, ballooning device always by default is enabled and ignores balloon = 0
.
System details:
Issue was introduced in v2 (https://github.com/Telmate/terraform-provider-proxmox/issues/631) and unfortunately not resolved.
Creating new resources works as expected, VM correctly created with memory
balloon
enabled (e.g.balloon = 2048
). Initial config (memory snippet):Decided to disable ballooning device (e.g.
balloon = 0
):In
terraform apply
output all looks fine, ballooning device should be disabled (0) and result shows asApply complete! Resources: 0 added, 1 changed, 0 destroyed.
:But as a result, after VM shutdown & start ballooning device still enabled in the PVE virtual machine:
When I try to run
terraform apply
again, it tries to disable device again and again with no success.Meanwhile ballooning device can only be removed through the Proxmox GUI.