published on Wednesday, Nov 4, 2026 by e-breuninger
published on Wednesday, Nov 4, 2026 by e-breuninger
A virtual machine interface (virtualization.vminterface).
From the official documentation:
Virtual machine interfaces behave similarly to device interfaces, and can be assigned to VRFs, and may have IP addresses, VLANs, and services attached to them. However, given their virtual nature, they lack properties pertaining to physical attributes. For example, VM interfaces do not have a physical type and cannot have cables attached to them.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as netbox from "@pulumi/netbox";
const test = new netbox.ClusterType("test", {name: "test-cluster-type"});
const testCluster = new netbox.Cluster("test", {
name: "test-cluster",
clusterTypeId: test.clusterTypeId,
});
const testVirtualMachine = new netbox.VirtualMachine("test", {
name: "test-virtual-machine",
clusterId: testCluster.clusterId,
});
const testA = new netbox.Vlan("test_a", {
name: "test-vlan-a",
vid: 100,
});
const testB = new netbox.Vlan("test_b", {
name: "test-vlan-b",
vid: 101,
});
const testVrf = new netbox.Vrf("test", {name: "test-vrf"});
const testVirtualMachineInterface = new netbox.VirtualMachineInterface("test", {
virtualMachineId: testVirtualMachine.virtualMachineId,
name: "test-virtual-machine-interface",
mtu: 1500,
mode: "tagged",
untaggedVlanId: testA.vlanId,
taggedVlanIds: [testB.vlanId],
vrfId: testVrf.vrfId,
description: "test-description",
});
import pulumi
import pulumi_netbox as netbox
test = netbox.ClusterType("test", name="test-cluster-type")
test_cluster = netbox.Cluster("test",
name="test-cluster",
cluster_type_id=test.cluster_type_id)
test_virtual_machine = netbox.VirtualMachine("test",
name="test-virtual-machine",
cluster_id=test_cluster.cluster_id)
test_a = netbox.Vlan("test_a",
name="test-vlan-a",
vid=100)
test_b = netbox.Vlan("test_b",
name="test-vlan-b",
vid=101)
test_vrf = netbox.Vrf("test", name="test-vrf")
test_virtual_machine_interface = netbox.VirtualMachineInterface("test",
virtual_machine_id=test_virtual_machine.virtual_machine_id,
name="test-virtual-machine-interface",
mtu=1500,
mode="tagged",
untagged_vlan_id=test_a.vlan_id,
tagged_vlan_ids=[test_b.vlan_id],
vrf_id=test_vrf.vrf_id,
description="test-description")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/netbox/v6/netbox"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
test, err := netbox.NewClusterType(ctx, "test", &netbox.ClusterTypeArgs{
Name: pulumi.String("test-cluster-type"),
})
if err != nil {
return err
}
testCluster, err := netbox.NewCluster(ctx, "test", &netbox.ClusterArgs{
Name: pulumi.String("test-cluster"),
ClusterTypeId: test.ClusterTypeId,
})
if err != nil {
return err
}
testVirtualMachine, err := netbox.NewVirtualMachine(ctx, "test", &netbox.VirtualMachineArgs{
Name: pulumi.String("test-virtual-machine"),
ClusterId: testCluster.ClusterId,
})
if err != nil {
return err
}
testA, err := netbox.NewVlan(ctx, "test_a", &netbox.VlanArgs{
Name: pulumi.String("test-vlan-a"),
Vid: pulumi.Float64(100),
})
if err != nil {
return err
}
testB, err := netbox.NewVlan(ctx, "test_b", &netbox.VlanArgs{
Name: pulumi.String("test-vlan-b"),
Vid: pulumi.Float64(101),
})
if err != nil {
return err
}
testVrf, err := netbox.NewVrf(ctx, "test", &netbox.VrfArgs{
Name: pulumi.String("test-vrf"),
})
if err != nil {
return err
}
_, err = netbox.NewVirtualMachineInterface(ctx, "test", &netbox.VirtualMachineInterfaceArgs{
VirtualMachineId: testVirtualMachine.VirtualMachineId,
Name: pulumi.String("test-virtual-machine-interface"),
Mtu: pulumi.Float64(1500),
Mode: pulumi.String("tagged"),
UntaggedVlanId: testA.VlanId,
TaggedVlanIds: pulumi.Float64Array{
testB.VlanId,
},
VrfId: testVrf.VrfId,
Description: pulumi.String("test-description"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Netbox = Pulumi.Netbox;
return await Deployment.RunAsync(() =>
{
var test = new Netbox.ClusterType("test", new()
{
Name = "test-cluster-type",
});
var testCluster = new Netbox.Cluster("test", new()
{
Name = "test-cluster",
ClusterTypeId = test.ClusterTypeId,
});
var testVirtualMachine = new Netbox.VirtualMachine("test", new()
{
Name = "test-virtual-machine",
ClusterId = testCluster.ClusterId,
});
var testA = new Netbox.Vlan("test_a", new()
{
Name = "test-vlan-a",
Vid = 100,
});
var testB = new Netbox.Vlan("test_b", new()
{
Name = "test-vlan-b",
Vid = 101,
});
var testVrf = new Netbox.Vrf("test", new()
{
Name = "test-vrf",
});
var testVirtualMachineInterface = new Netbox.VirtualMachineInterface("test", new()
{
VirtualMachineId = testVirtualMachine.VirtualMachineId,
Name = "test-virtual-machine-interface",
Mtu = 1500,
Mode = "tagged",
UntaggedVlanId = testA.VlanId,
TaggedVlanIds = new[]
{
testB.VlanId,
},
VrfId = testVrf.VrfId,
Description = "test-description",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.netbox.ClusterType;
import com.pulumi.netbox.ClusterTypeArgs;
import com.pulumi.netbox.Cluster;
import com.pulumi.netbox.ClusterArgs;
import com.pulumi.netbox.VirtualMachine;
import com.pulumi.netbox.VirtualMachineArgs;
import com.pulumi.netbox.Vlan;
import com.pulumi.netbox.VlanArgs;
import com.pulumi.netbox.Vrf;
import com.pulumi.netbox.VrfArgs;
import com.pulumi.netbox.VirtualMachineInterface;
import com.pulumi.netbox.VirtualMachineInterfaceArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var test = new ClusterType("test", ClusterTypeArgs.builder()
.name("test-cluster-type")
.build());
var testCluster = new Cluster("testCluster", ClusterArgs.builder()
.name("test-cluster")
.clusterTypeId(test.clusterTypeId())
.build());
var testVirtualMachine = new VirtualMachine("testVirtualMachine", VirtualMachineArgs.builder()
.name("test-virtual-machine")
.clusterId(testCluster.clusterId())
.build());
var testA = new Vlan("testA", VlanArgs.builder()
.name("test-vlan-a")
.vid(100.0)
.build());
var testB = new Vlan("testB", VlanArgs.builder()
.name("test-vlan-b")
.vid(101.0)
.build());
var testVrf = new Vrf("testVrf", VrfArgs.builder()
.name("test-vrf")
.build());
var testVirtualMachineInterface = new VirtualMachineInterface("testVirtualMachineInterface", VirtualMachineInterfaceArgs.builder()
.virtualMachineId(testVirtualMachine.virtualMachineId())
.name("test-virtual-machine-interface")
.mtu(1500.0)
.mode("tagged")
.untaggedVlanId(testA.vlanId())
.taggedVlanIds(testB.vlanId())
.vrfId(testVrf.vrfId())
.description("test-description")
.build());
}
}
resources:
test:
type: netbox:ClusterType
properties:
name: test-cluster-type
testCluster:
type: netbox:Cluster
name: test
properties:
name: test-cluster
clusterTypeId: ${test.clusterTypeId}
testVirtualMachine:
type: netbox:VirtualMachine
name: test
properties:
name: test-virtual-machine
clusterId: ${testCluster.clusterId}
testA:
type: netbox:Vlan
name: test_a
properties:
name: test-vlan-a
vid: 100
testB:
type: netbox:Vlan
name: test_b
properties:
name: test-vlan-b
vid: 101
testVrf:
type: netbox:Vrf
name: test
properties:
name: test-vrf
testVirtualMachineInterface:
type: netbox:VirtualMachineInterface
name: test
properties:
virtualMachineId: ${testVirtualMachine.virtualMachineId}
name: test-virtual-machine-interface
mtu: 1500
mode: tagged
untaggedVlanId: ${testA.vlanId}
taggedVlanIds:
- ${testB.vlanId}
vrfId: ${testVrf.vrfId}
description: test-description
Example coming soon!
Create VirtualMachineInterface Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new VirtualMachineInterface(name: string, args: VirtualMachineInterfaceArgs, opts?: CustomResourceOptions);@overload
def VirtualMachineInterface(resource_name: str,
args: VirtualMachineInterfaceArgs,
opts: Optional[ResourceOptions] = None)
@overload
def VirtualMachineInterface(resource_name: str,
opts: Optional[ResourceOptions] = None,
virtual_machine_id: Optional[float] = None,
parent_id: Optional[float] = None,
tags: Optional[Sequence[str]] = None,
enabled: Optional[bool] = None,
mode: Optional[str] = None,
mtu: Optional[float] = None,
name: Optional[str] = None,
description: Optional[str] = None,
qinq_svlan_id: Optional[float] = None,
owner_id: Optional[float] = None,
tagged_vlan_ids: Optional[Sequence[float]] = None,
bridge_id: Optional[float] = None,
untagged_vlan_id: Optional[float] = None,
custom_fields: Optional[Mapping[str, str]] = None,
vlan_translation_policy_id: Optional[float] = None,
vrf_id: Optional[float] = None)func NewVirtualMachineInterface(ctx *Context, name string, args VirtualMachineInterfaceArgs, opts ...ResourceOption) (*VirtualMachineInterface, error)public VirtualMachineInterface(string name, VirtualMachineInterfaceArgs args, CustomResourceOptions? opts = null)
public VirtualMachineInterface(String name, VirtualMachineInterfaceArgs args)
public VirtualMachineInterface(String name, VirtualMachineInterfaceArgs args, CustomResourceOptions options)
type: netbox:VirtualMachineInterface
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "netbox_virtual_machine_interface" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args VirtualMachineInterfaceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args VirtualMachineInterfaceArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args VirtualMachineInterfaceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args VirtualMachineInterfaceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args VirtualMachineInterfaceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var virtualMachineInterfaceResource = new Netbox.VirtualMachineInterface("virtualMachineInterfaceResource", new()
{
VirtualMachineId = 0.0,
ParentId = 0.0,
Tags = new[]
{
"string",
},
Enabled = false,
Mode = "string",
Mtu = 0.0,
Name = "string",
Description = "string",
QinqSvlanId = 0.0,
OwnerId = 0.0,
TaggedVlanIds = new[]
{
0.0,
},
BridgeId = 0.0,
UntaggedVlanId = 0.0,
CustomFields =
{
{ "string", "string" },
},
VlanTranslationPolicyId = 0.0,
VrfId = 0.0,
});
example, err := netbox.NewVirtualMachineInterface(ctx, "virtualMachineInterfaceResource", &netbox.VirtualMachineInterfaceArgs{
VirtualMachineId: pulumi.Float64(0),
ParentId: pulumi.Float64(0),
Tags: pulumi.StringArray{
pulumi.String("string"),
},
Enabled: pulumi.Bool(false),
Mode: pulumi.String("string"),
Mtu: pulumi.Float64(0),
Name: pulumi.String("string"),
Description: pulumi.String("string"),
QinqSvlanId: pulumi.Float64(0),
OwnerId: pulumi.Float64(0),
TaggedVlanIds: pulumi.Float64Array{
pulumi.Float64(0),
},
BridgeId: pulumi.Float64(0),
UntaggedVlanId: pulumi.Float64(0),
CustomFields: pulumi.StringMap{
"string": pulumi.String("string"),
},
VlanTranslationPolicyId: pulumi.Float64(0),
VrfId: pulumi.Float64(0),
})
resource "netbox_virtual_machine_interface" "virtualMachineInterfaceResource" {
lifecycle {
create_before_destroy = true
}
virtual_machine_id = 0
parent_id = 0
tags = ["string"]
enabled = false
mode = "string"
mtu = 0
name = "string"
description = "string"
qinq_svlan_id = 0
owner_id = 0
tagged_vlan_ids = [0]
bridge_id = 0
untagged_vlan_id = 0
custom_fields = {
"string" = "string"
}
vlan_translation_policy_id = 0
vrf_id = 0
}
var virtualMachineInterfaceResource = new VirtualMachineInterface("virtualMachineInterfaceResource", VirtualMachineInterfaceArgs.builder()
.virtualMachineId(0.0)
.parentId(0.0)
.tags("string")
.enabled(false)
.mode("string")
.mtu(0.0)
.name("string")
.description("string")
.qinqSvlanId(0.0)
.ownerId(0.0)
.taggedVlanIds(0.0)
.bridgeId(0.0)
.untaggedVlanId(0.0)
.customFields(Map.of("string", "string"))
.vlanTranslationPolicyId(0.0)
.vrfId(0.0)
.build());
virtual_machine_interface_resource = netbox.VirtualMachineInterface("virtualMachineInterfaceResource",
virtual_machine_id=float(0),
parent_id=float(0),
tags=["string"],
enabled=False,
mode="string",
mtu=float(0),
name="string",
description="string",
qinq_svlan_id=float(0),
owner_id=float(0),
tagged_vlan_ids=[float(0)],
bridge_id=float(0),
untagged_vlan_id=float(0),
custom_fields={
"string": "string",
},
vlan_translation_policy_id=float(0),
vrf_id=float(0))
const virtualMachineInterfaceResource = new netbox.VirtualMachineInterface("virtualMachineInterfaceResource", {
virtualMachineId: 0,
parentId: 0,
tags: ["string"],
enabled: false,
mode: "string",
mtu: 0,
name: "string",
description: "string",
qinqSvlanId: 0,
ownerId: 0,
taggedVlanIds: [0],
bridgeId: 0,
untaggedVlanId: 0,
customFields: {
string: "string",
},
vlanTranslationPolicyId: 0,
vrfId: 0,
});
type: netbox:VirtualMachineInterface
properties:
bridgeId: 0
customFields:
string: string
description: string
enabled: false
mode: string
mtu: 0
name: string
ownerId: 0
parentId: 0
qinqSvlanId: 0
taggedVlanIds:
- 0
tags:
- string
untaggedVlanId: 0
virtualMachineId: 0
vlanTranslationPolicyId: 0
vrfId: 0
VirtualMachineInterface Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The VirtualMachineInterface resource accepts the following input properties:
- Virtual
Machine doubleId - Id of the virtual machine.
- Bridge
Id double - Id of the bridged interface.
- Custom
Fields Dictionary<string, string> - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- Description string
- Enabled bool
- Whether the interface is enabled.
- Mode string
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- Mtu double
- MTU in bytes. Must be a whole number.
- Name string
- Owner
Id double - Id of the owner the object is assigned to.
- Parent
Id double - Id of the parent interface.
- Qinq
Svlan doubleId - Id of the Q-in-Q service VLAN.
- Tagged
Vlan List<double>Ids - Ids of the tagged VLANs.
- List<string>
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- Untagged
Vlan doubleId - Id of the untagged VLAN.
- Vlan
Translation doublePolicy Id - Id of the VLAN translation policy.
- Vrf
Id double - Id of the VRF.
- Virtual
Machine float64Id - Id of the virtual machine.
- Bridge
Id float64 - Id of the bridged interface.
- Custom
Fields map[string]string - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- Description string
- Enabled bool
- Whether the interface is enabled.
- Mode string
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- Mtu float64
- MTU in bytes. Must be a whole number.
- Name string
- Owner
Id float64 - Id of the owner the object is assigned to.
- Parent
Id float64 - Id of the parent interface.
- Qinq
Svlan float64Id - Id of the Q-in-Q service VLAN.
- Tagged
Vlan []float64Ids - Ids of the tagged VLANs.
- []string
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- Untagged
Vlan float64Id - Id of the untagged VLAN.
- Vlan
Translation float64Policy Id - Id of the VLAN translation policy.
- Vrf
Id float64 - Id of the VRF.
- virtual_
machine_ numberid - Id of the virtual machine.
- bridge_
id number - Id of the bridged interface.
- custom_
fields map(string) - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description string
- enabled bool
- Whether the interface is enabled.
- mode string
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu number
- MTU in bytes. Must be a whole number.
- name string
- owner_
id number - Id of the owner the object is assigned to.
- parent_
id number - Id of the parent interface.
- qinq_
svlan_ numberid - Id of the Q-in-Q service VLAN.
- tagged_
vlan_ list(number)ids - Ids of the tagged VLANs.
- list(string)
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- untagged_
vlan_ numberid - Id of the untagged VLAN.
- vlan_
translation_ numberpolicy_ id - Id of the VLAN translation policy.
- vrf_
id number - Id of the VRF.
- virtual
Machine DoubleId - Id of the virtual machine.
- bridge
Id Double - Id of the bridged interface.
- custom
Fields Map<String,String> - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description String
- enabled Boolean
- Whether the interface is enabled.
- mode String
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu Double
- MTU in bytes. Must be a whole number.
- name String
- owner
Id Double - Id of the owner the object is assigned to.
- parent
Id Double - Id of the parent interface.
- qinq
Svlan DoubleId - Id of the Q-in-Q service VLAN.
- tagged
Vlan List<Double>Ids - Ids of the tagged VLANs.
- List<String>
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- untagged
Vlan DoubleId - Id of the untagged VLAN.
- vlan
Translation DoublePolicy Id - Id of the VLAN translation policy.
- vrf
Id Double - Id of the VRF.
- virtual
Machine numberId - Id of the virtual machine.
- bridge
Id number - Id of the bridged interface.
- custom
Fields {[key: string]: string} - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description string
- enabled boolean
- Whether the interface is enabled.
- mode string
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu number
- MTU in bytes. Must be a whole number.
- name string
- owner
Id number - Id of the owner the object is assigned to.
- parent
Id number - Id of the parent interface.
- qinq
Svlan numberId - Id of the Q-in-Q service VLAN.
- tagged
Vlan number[]Ids - Ids of the tagged VLANs.
- string[]
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- untagged
Vlan numberId - Id of the untagged VLAN.
- vlan
Translation numberPolicy Id - Id of the VLAN translation policy.
- vrf
Id number - Id of the VRF.
- virtual_
machine_ floatid - Id of the virtual machine.
- bridge_
id float - Id of the bridged interface.
- custom_
fields Mapping[str, str] - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description str
- enabled bool
- Whether the interface is enabled.
- mode str
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu float
- MTU in bytes. Must be a whole number.
- name str
- owner_
id float - Id of the owner the object is assigned to.
- parent_
id float - Id of the parent interface.
- qinq_
svlan_ floatid - Id of the Q-in-Q service VLAN.
- tagged_
vlan_ Sequence[float]ids - Ids of the tagged VLANs.
- Sequence[str]
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- untagged_
vlan_ floatid - Id of the untagged VLAN.
- vlan_
translation_ floatpolicy_ id - Id of the VLAN translation policy.
- vrf_
id float - Id of the VRF.
- virtual
Machine NumberId - Id of the virtual machine.
- bridge
Id Number - Id of the bridged interface.
- custom
Fields Map<String> - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description String
- enabled Boolean
- Whether the interface is enabled.
- mode String
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu Number
- MTU in bytes. Must be a whole number.
- name String
- owner
Id Number - Id of the owner the object is assigned to.
- parent
Id Number - Id of the parent interface.
- qinq
Svlan NumberId - Id of the Q-in-Q service VLAN.
- tagged
Vlan List<Number>Ids - Ids of the tagged VLANs.
- List<String>
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- untagged
Vlan NumberId - Id of the untagged VLAN.
- vlan
Translation NumberPolicy Id - Id of the VLAN translation policy.
- vrf
Id Number - Id of the VRF.
Outputs
All input properties are implicitly available as output properties. Additionally, the VirtualMachineInterface resource produces the following output properties:
- Created string
- Id string
- The provider-assigned unique ID for this managed resource.
- Last
Updated string - List<string>
- Slugs of all tags on the object, including the provider's default_tags.
- Url string
- Virtual
Machine doubleInterface Id - NetBox id.
- Created string
- Id string
- The provider-assigned unique ID for this managed resource.
- Last
Updated string - []string
- Slugs of all tags on the object, including the provider's default_tags.
- Url string
- Virtual
Machine float64Interface Id - NetBox id.
- created string
- id string
- The provider-assigned unique ID for this managed resource.
- last_
updated string - list(string)
- Slugs of all tags on the object, including the provider's default_tags.
- url string
- virtual_
machine_ numberinterface_ id - NetBox id.
- created String
- id String
- The provider-assigned unique ID for this managed resource.
- last
Updated String - List<String>
- Slugs of all tags on the object, including the provider's default_tags.
- url String
- virtual
Machine DoubleInterface Id - NetBox id.
- created string
- id string
- The provider-assigned unique ID for this managed resource.
- last
Updated string - string[]
- Slugs of all tags on the object, including the provider's default_tags.
- url string
- virtual
Machine numberInterface Id - NetBox id.
- created str
- id str
- The provider-assigned unique ID for this managed resource.
- last_
updated str - Sequence[str]
- Slugs of all tags on the object, including the provider's default_tags.
- url str
- virtual_
machine_ floatinterface_ id - NetBox id.
- created String
- id String
- The provider-assigned unique ID for this managed resource.
- last
Updated String - List<String>
- Slugs of all tags on the object, including the provider's default_tags.
- url String
- virtual
Machine NumberInterface Id - NetBox id.
Look up Existing VirtualMachineInterface Resource
Get an existing VirtualMachineInterface resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: VirtualMachineInterfaceState, opts?: CustomResourceOptions): VirtualMachineInterface@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
bridge_id: Optional[float] = None,
created: Optional[str] = None,
custom_fields: Optional[Mapping[str, str]] = None,
description: Optional[str] = None,
enabled: Optional[bool] = None,
last_updated: Optional[str] = None,
mode: Optional[str] = None,
mtu: Optional[float] = None,
name: Optional[str] = None,
owner_id: Optional[float] = None,
parent_id: Optional[float] = None,
qinq_svlan_id: Optional[float] = None,
tagged_vlan_ids: Optional[Sequence[float]] = None,
tags: Optional[Sequence[str]] = None,
tags_alls: Optional[Sequence[str]] = None,
untagged_vlan_id: Optional[float] = None,
url: Optional[str] = None,
virtual_machine_id: Optional[float] = None,
virtual_machine_interface_id: Optional[float] = None,
vlan_translation_policy_id: Optional[float] = None,
vrf_id: Optional[float] = None) -> VirtualMachineInterfacefunc GetVirtualMachineInterface(ctx *Context, name string, id IDInput, state *VirtualMachineInterfaceState, opts ...ResourceOption) (*VirtualMachineInterface, error)public static VirtualMachineInterface Get(string name, Input<string> id, VirtualMachineInterfaceState? state, CustomResourceOptions? opts = null)public static VirtualMachineInterface get(String name, Output<String> id, VirtualMachineInterfaceState state, CustomResourceOptions options)resources: _: type: netbox:VirtualMachineInterface get: id: ${id}import {
to = netbox_virtual_machine_interface.example
id = "${id}"
}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Bridge
Id double - Id of the bridged interface.
- Created string
- Custom
Fields Dictionary<string, string> - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- Description string
- Enabled bool
- Whether the interface is enabled.
- Last
Updated string - Mode string
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- Mtu double
- MTU in bytes. Must be a whole number.
- Name string
- Owner
Id double - Id of the owner the object is assigned to.
- Parent
Id double - Id of the parent interface.
- Qinq
Svlan doubleId - Id of the Q-in-Q service VLAN.
- Tagged
Vlan List<double>Ids - Ids of the tagged VLANs.
- List<string>
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- List<string>
- Slugs of all tags on the object, including the provider's default_tags.
- Untagged
Vlan doubleId - Id of the untagged VLAN.
- Url string
- Virtual
Machine doubleId - Id of the virtual machine.
- Virtual
Machine doubleInterface Id - NetBox id.
- Vlan
Translation doublePolicy Id - Id of the VLAN translation policy.
- Vrf
Id double - Id of the VRF.
- Bridge
Id float64 - Id of the bridged interface.
- Created string
- Custom
Fields map[string]string - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- Description string
- Enabled bool
- Whether the interface is enabled.
- Last
Updated string - Mode string
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- Mtu float64
- MTU in bytes. Must be a whole number.
- Name string
- Owner
Id float64 - Id of the owner the object is assigned to.
- Parent
Id float64 - Id of the parent interface.
- Qinq
Svlan float64Id - Id of the Q-in-Q service VLAN.
- Tagged
Vlan []float64Ids - Ids of the tagged VLANs.
- []string
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- []string
- Slugs of all tags on the object, including the provider's default_tags.
- Untagged
Vlan float64Id - Id of the untagged VLAN.
- Url string
- Virtual
Machine float64Id - Id of the virtual machine.
- Virtual
Machine float64Interface Id - NetBox id.
- Vlan
Translation float64Policy Id - Id of the VLAN translation policy.
- Vrf
Id float64 - Id of the VRF.
- bridge_
id number - Id of the bridged interface.
- created string
- custom_
fields map(string) - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description string
- enabled bool
- Whether the interface is enabled.
- last_
updated string - mode string
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu number
- MTU in bytes. Must be a whole number.
- name string
- owner_
id number - Id of the owner the object is assigned to.
- parent_
id number - Id of the parent interface.
- qinq_
svlan_ numberid - Id of the Q-in-Q service VLAN.
- tagged_
vlan_ list(number)ids - Ids of the tagged VLANs.
- list(string)
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- list(string)
- Slugs of all tags on the object, including the provider's default_tags.
- untagged_
vlan_ numberid - Id of the untagged VLAN.
- url string
- virtual_
machine_ numberid - Id of the virtual machine.
- virtual_
machine_ numberinterface_ id - NetBox id.
- vlan_
translation_ numberpolicy_ id - Id of the VLAN translation policy.
- vrf_
id number - Id of the VRF.
- bridge
Id Double - Id of the bridged interface.
- created String
- custom
Fields Map<String,String> - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description String
- enabled Boolean
- Whether the interface is enabled.
- last
Updated String - mode String
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu Double
- MTU in bytes. Must be a whole number.
- name String
- owner
Id Double - Id of the owner the object is assigned to.
- parent
Id Double - Id of the parent interface.
- qinq
Svlan DoubleId - Id of the Q-in-Q service VLAN.
- tagged
Vlan List<Double>Ids - Ids of the tagged VLANs.
- List<String>
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- List<String>
- Slugs of all tags on the object, including the provider's default_tags.
- untagged
Vlan DoubleId - Id of the untagged VLAN.
- url String
- virtual
Machine DoubleId - Id of the virtual machine.
- virtual
Machine DoubleInterface Id - NetBox id.
- vlan
Translation DoublePolicy Id - Id of the VLAN translation policy.
- vrf
Id Double - Id of the VRF.
- bridge
Id number - Id of the bridged interface.
- created string
- custom
Fields {[key: string]: string} - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description string
- enabled boolean
- Whether the interface is enabled.
- last
Updated string - mode string
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu number
- MTU in bytes. Must be a whole number.
- name string
- owner
Id number - Id of the owner the object is assigned to.
- parent
Id number - Id of the parent interface.
- qinq
Svlan numberId - Id of the Q-in-Q service VLAN.
- tagged
Vlan number[]Ids - Ids of the tagged VLANs.
- string[]
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- string[]
- Slugs of all tags on the object, including the provider's default_tags.
- untagged
Vlan numberId - Id of the untagged VLAN.
- url string
- virtual
Machine numberId - Id of the virtual machine.
- virtual
Machine numberInterface Id - NetBox id.
- vlan
Translation numberPolicy Id - Id of the VLAN translation policy.
- vrf
Id number - Id of the VRF.
- bridge_
id float - Id of the bridged interface.
- created str
- custom_
fields Mapping[str, str] - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description str
- enabled bool
- Whether the interface is enabled.
- last_
updated str - mode str
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu float
- MTU in bytes. Must be a whole number.
- name str
- owner_
id float - Id of the owner the object is assigned to.
- parent_
id float - Id of the parent interface.
- qinq_
svlan_ floatid - Id of the Q-in-Q service VLAN.
- tagged_
vlan_ Sequence[float]ids - Ids of the tagged VLANs.
- Sequence[str]
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- Sequence[str]
- Slugs of all tags on the object, including the provider's default_tags.
- untagged_
vlan_ floatid - Id of the untagged VLAN.
- url str
- virtual_
machine_ floatid - Id of the virtual machine.
- virtual_
machine_ floatinterface_ id - NetBox id.
- vlan_
translation_ floatpolicy_ id - Id of the VLAN translation policy.
- vrf_
id float - Id of the VRF.
- bridge
Id Number - Id of the bridged interface.
- created String
- custom
Fields Map<String> - Custom field values by field name. Every value is a string; NetBox coerces numbers and booleans. An object field holds the related object's id, e.g. "12", a multiobject field a JSON list of ids in any order, e.g. jsonencode([12, 13]). A key removed from the map is cleared in NetBox (set {} to clear all).
- description String
- enabled Boolean
- Whether the interface is enabled.
- last
Updated String - mode String
- 802.1Q tagging mode. One of: access, tagged, tagged-all, q-in-q.
- mtu Number
- MTU in bytes. Must be a whole number.
- name String
- owner
Id Number - Id of the owner the object is assigned to.
- parent
Id Number - Id of the parent interface.
- qinq
Svlan NumberId - Id of the Q-in-Q service VLAN.
- tagged
Vlan List<Number>Ids - Ids of the tagged VLANs.
- List<String>
- Slugs of the tags assigned to the object (the provider's defaulttags are added on top, see tagsall).
- List<String>
- Slugs of all tags on the object, including the provider's default_tags.
- untagged
Vlan NumberId - Id of the untagged VLAN.
- url String
- virtual
Machine NumberId - Id of the virtual machine.
- virtual
Machine NumberInterface Id - NetBox id.
- vlan
Translation NumberPolicy Id - Id of the VLAN translation policy.
- vrf
Id Number - Id of the VRF.
Import
In Terraform v1.5.0 and later, the import block can be used with the id attribute, for example:
terraform
import {
to = netbox_virtual_machine_interface.test
id = “123”
}
The pulumi import command can be used, for example:
$ pulumi import netbox:index/virtualMachineInterface:VirtualMachineInterface test 123
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- netbox e-breuninger/terraform-provider-netbox
- License
- Notes
- This Pulumi package is based on the
netboxTerraform Provider.
published on Wednesday, Nov 4, 2026 by e-breuninger