You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I can't use local_context_data on a virtual machine because the module asks for a string but the API for JSON.
Version
Netbox version
v2.9.9
Terraform version
0.15.1
Provider version
1.3.0
Issue details
Affected Data(s) / Resource(s)
resource netbox_virtualization_vm
Terraform Configuration Files
resource"netbox_virtualization_vm""vm" {
name=vsphere_virtual_machine.vm.namedisk=vsphere_virtual_machine.vm.disk[0].sizememory=vsphere_virtual_machine.vm.memorycluster_id=4local_context_data={"test":"test"}
tag {
name="all"slug="all"
}
}
Terraform Output
When using a dict:
│ Error: Incorrect attribute value type
│
│ on vm.tf line 78, in resource "netbox_virtualization_vm" "vm":
│ 78: local_context_data = {"test": "test"}
│
│ Inappropriate value for attribute "local_context_data": string required.
When using a string:
╷
│ Error: [POST /virtualization/virtual-machines/][400] virtualization_virtual-machines_create default map[local_context_data:[JSON data must be in object form. Example: {"foo": 123}]]
│
│ on vm.tf line 73, in resource "netbox_virtualization_vm" "vm":
│ 73: resource "netbox_virtualization_vm" "vm" {
│
Behaviors
Actual Behavior
The module only accepting a string for local_context_data meanwhile the API needs it in JSON format.
Expected Behavior
The module accepting JSON format for local_context_data
Steps to Reproduce
terraform plan
Terraform apply
The text was updated successfully, but these errors were encountered:
caskalverboer
changed the title
[Main title for your issue here]
local_context_data on virtual machine is asking for a string but needs te be JSON
Apr 29, 2021
Summary
I can't use local_context_data on a virtual machine because the module asks for a string but the API for JSON.
Version
Netbox version
Terraform version
Provider version
Issue details
Affected Data(s) / Resource(s)
Terraform Configuration Files
Terraform Output
Behaviors
Actual Behavior
The module only accepting a string for local_context_data meanwhile the API needs it in JSON format.
Expected Behavior
The module accepting JSON format for local_context_data
Steps to Reproduce
terraform plan
The text was updated successfully, but these errors were encountered: