bpg / terraform-provider-proxmox

Terraform Provider for Proxmox
https://registry.terraform.io/providers/bpg/proxmox
Mozilla Public License 2.0
884 stars 140 forks source link

sequential VM ids not working correctly with templates #1567

Closed camaeel closed 1 month ago

camaeel commented 1 month ago

Describe the bug I have a project that creates a bunch of VMs (kubernetes cluster with 7 nodes). This project uses default provider config (I assume default is random_vm_id = false). I have:

When I try to provision this cluster from scratch I get error:



**To Reproduce**
Steps to reproduce the behavior:

1. Create VMs and VM templates with some IDs
2. Try to provision few VMs with this provider 
3. See error

**Expected behavior**
When random_vm_id=false (or unset) I would like to have the old behaviour from version <= 0.65.0

- Single or clustered Proxmox: single node
- Proxmox version: 8.2.7
- Provider version (ideally it should be the latest version): 0.66.0
- Terraform/OpenTofu version: terraform 1.9.5 + terragrunt v0.67.4
- OS (where you run Terraform/OpenTofu from): Macos Seqoia 
- Debug logs (`TF_LOG=DEBUG terraform apply`): with TF_LOG=DEBUG it seems to work properly. Maybe there is some kind of race condition when provisioning multiple VMs in parallel. 
bpg commented 1 month ago

Thanks @camaeel, missed this use case 🤦🏼

bpg commented 1 month ago

@all-contributors please add @camaeel for bug

allcontributors[bot] commented 1 month ago

@bpg

I've put up a pull request to add @camaeel! :tada:

camaeel commented 1 month ago

Works as expected, thanx.