smutel / terraform-provider-netbox

Terraform provider for Netbox
ISC License
58 stars 19 forks source link

Import does not work for virtualization_vm_primary_ip #188

Closed amhn closed 1 year ago

amhn commented 1 year ago

Summary

Importing a netbox_virtualization_vm_primary_ip by vm id fails with an error.

Version

Netbox version

3.3.10

Terraform version

1.4.0

Provider version

6.1.1

Issue details

Affected Data(s) / Resource(s)

Terraform Output

╷
│ Error: Cannot import non-existent remote object
│ 
│ While attempting to import an existing object to "module.this.netbox_virtualization_vm_primary_ip.virtual_machines[\"hprv-001_mysql\"]", the provider detected that no object exists with the given id. Only pre-existing objects can be imported;
│ check that the id is correct and that it is associated with the provider's configured region or endpoint, or use "terraform apply" to create a new remote object for this resource.
╵

Behaviors

Actual Behavior

Error. See above

Expected Behavior

Resource is imported

Steps to Reproduce

terraform import 'netbox_virtualization_vm_primary_ip.vm_primary_ip' 1