1. Packages
  2. Proxmox Virtual Environment (Proxmox VE)
  3. API Docs
  4. network
  5. network/linux
  6. VlanLegacy
Viewing docs for Proxmox Virtual Environment (Proxmox VE) v8.0.0
published on Sunday, Apr 5, 2026 by Daniel Muehlbachler-Pietrzykowski
proxmoxve logo
Viewing docs for Proxmox Virtual Environment (Proxmox VE) v8.0.0
published on Sunday, Apr 5, 2026 by Daniel Muehlbachler-Pietrzykowski

    Deprecated: Use proxmoxve.network/linux.Vlan instead. This resource will be removed in v1.0.

    Manages a Linux VLAN network interface in a Proxmox VE node.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as proxmoxve from "@muhlba91/pulumi-proxmoxve";
    
    // using VLAN tag
    const vlan99 = new proxmoxve.network.linux.VlanLegacy("vlan99", {
        nodeName: "pve",
        name: "eno0.99",
        comment: "VLAN 99",
    });
    // using custom network interface name
    const vlan98 = new proxmoxve.network.linux.VlanLegacy("vlan98", {
        nodeName: "pve",
        name: "vlan_lab",
        "interface": "eno0",
        vlan: 98,
        comment: "VLAN 98",
    });
    
    import pulumi
    import pulumi_proxmoxve as proxmoxve
    
    # using VLAN tag
    vlan99 = proxmoxve.network.linux.VlanLegacy("vlan99",
        node_name="pve",
        name="eno0.99",
        comment="VLAN 99")
    # using custom network interface name
    vlan98 = proxmoxve.network.linux.VlanLegacy("vlan98",
        node_name="pve",
        name="vlan_lab",
        interface="eno0",
        vlan=98,
        comment="VLAN 98")
    
    package main
    
    import (
    	"github.com/muhlba91/pulumi-proxmoxve/sdk/v8/go/proxmoxve/network"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// using VLAN tag
    		_, err := network.NewVlanLegacy(ctx, "vlan99", &network.VlanLegacyArgs{
    			NodeName: pulumi.String("pve"),
    			Name:     pulumi.String("eno0.99"),
    			Comment:  pulumi.String("VLAN 99"),
    		})
    		if err != nil {
    			return err
    		}
    		// using custom network interface name
    		_, err = network.NewVlanLegacy(ctx, "vlan98", &network.VlanLegacyArgs{
    			NodeName:  pulumi.String("pve"),
    			Name:      pulumi.String("vlan_lab"),
    			Interface: pulumi.String("eno0"),
    			Vlan:      pulumi.Int(98),
    			Comment:   pulumi.String("VLAN 98"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using ProxmoxVE = Pulumi.ProxmoxVE;
    
    return await Deployment.RunAsync(() => 
    {
        // using VLAN tag
        var vlan99 = new ProxmoxVE.Network.Linux.VlanLegacy("vlan99", new()
        {
            NodeName = "pve",
            Name = "eno0.99",
            Comment = "VLAN 99",
        });
    
        // using custom network interface name
        var vlan98 = new ProxmoxVE.Network.Linux.VlanLegacy("vlan98", new()
        {
            NodeName = "pve",
            Name = "vlan_lab",
            Interface = "eno0",
            VlanId = %!v(PANIC=Format method: fatal: A failure has occurred: unexpected literal type in GenLiteralValueExpression: cty.NumberIntVal(98) (example.pp:13,15-17)),
            Comment = "VLAN 98",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import io.muehlbachler.pulumi.proxmoxve.network.VlanLegacy;
    import io.muehlbachler.pulumi.proxmoxve.network.VlanLegacyArgs;
    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) {
            // using VLAN tag
            var vlan99 = new VlanLegacy("vlan99", VlanLegacyArgs.builder()
                .nodeName("pve")
                .name("eno0.99")
                .comment("VLAN 99")
                .build());
    
            // using custom network interface name
            var vlan98 = new VlanLegacy("vlan98", VlanLegacyArgs.builder()
                .nodeName("pve")
                .name("vlan_lab")
                .interface_("eno0")
                .vlan(%!v(PANIC=Format method: fatal: A failure has occurred: unexpected literal type in GenLiteralValueExpression: cty.NumberIntVal(98) (example.pp:13,15-17)))
                .comment("VLAN 98")
                .build());
    
        }
    }
    
    resources:
      # using VLAN tag
      vlan99:
        type: proxmoxve:network/linux:VlanLegacy
        properties:
          nodeName: pve
          name: eno0.99
          comment: VLAN 99
      # using custom network interface name
      vlan98:
        type: proxmoxve:network/linux:VlanLegacy
        properties:
          nodeName: pve
          name: vlan_lab
          interface: eno0
          vlan: 98
          comment: VLAN 98
    

    Create VlanLegacy Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new VlanLegacy(name: string, args: VlanLegacyArgs, opts?: CustomResourceOptions);
    @overload
    def VlanLegacy(resource_name: str,
                   args: VlanLegacyArgs,
                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def VlanLegacy(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   node_name: Optional[str] = None,
                   address: Optional[str] = None,
                   address6: Optional[str] = None,
                   autostart: Optional[bool] = None,
                   comment: Optional[str] = None,
                   gateway: Optional[str] = None,
                   gateway6: Optional[str] = None,
                   interface: Optional[str] = None,
                   mtu: Optional[int] = None,
                   name: Optional[str] = None,
                   timeout_reload: Optional[int] = None,
                   vlan: Optional[int] = None)
    func NewVlanLegacy(ctx *Context, name string, args VlanLegacyArgs, opts ...ResourceOption) (*VlanLegacy, error)
    public VlanLegacy(string name, VlanLegacyArgs args, CustomResourceOptions? opts = null)
    public VlanLegacy(String name, VlanLegacyArgs args)
    public VlanLegacy(String name, VlanLegacyArgs args, CustomResourceOptions options)
    
    type: proxmoxve:network/linux/vlanLegacy:VlanLegacy
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args VlanLegacyArgs
    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 VlanLegacyArgs
    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 VlanLegacyArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args VlanLegacyArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args VlanLegacyArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    VlanLegacy 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 VlanLegacy resource accepts the following input properties:

    NodeName string
    The name of the node.
    Address string
    The interface IPv4/CIDR address.
    Address6 string
    The interface IPv6/CIDR address.
    Autostart bool
    Automatically start interface on boot (defaults to true).
    Comment string
    Comment for the interface.
    Gateway string
    Default gateway address.
    Gateway6 string
    Default IPv6 gateway address.
    Interface string
    The VLAN raw device. See also name.
    Mtu int
    The interface MTU.
    Name string
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    TimeoutReload int
    Timeout for network reload operations in seconds (defaults to 100).
    vlanId int
    The VLAN tag. See also name.
    NodeName string
    The name of the node.
    Address string
    The interface IPv4/CIDR address.
    Address6 string
    The interface IPv6/CIDR address.
    Autostart bool
    Automatically start interface on boot (defaults to true).
    Comment string
    Comment for the interface.
    Gateway string
    Default gateway address.
    Gateway6 string
    Default IPv6 gateway address.
    Interface string
    The VLAN raw device. See also name.
    Mtu int
    The interface MTU.
    Name string
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    TimeoutReload int
    Timeout for network reload operations in seconds (defaults to 100).
    Vlan int
    The VLAN tag. See also name.
    nodeName String
    The name of the node.
    address String
    The interface IPv4/CIDR address.
    address6 String
    The interface IPv6/CIDR address.
    autostart Boolean
    Automatically start interface on boot (defaults to true).
    comment String
    Comment for the interface.
    gateway String
    Default gateway address.
    gateway6 String
    Default IPv6 gateway address.
    interface_ String
    The VLAN raw device. See also name.
    mtu Integer
    The interface MTU.
    name String
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    timeoutReload Integer
    Timeout for network reload operations in seconds (defaults to 100).
    vlan Integer
    The VLAN tag. See also name.
    nodeName string
    The name of the node.
    address string
    The interface IPv4/CIDR address.
    address6 string
    The interface IPv6/CIDR address.
    autostart boolean
    Automatically start interface on boot (defaults to true).
    comment string
    Comment for the interface.
    gateway string
    Default gateway address.
    gateway6 string
    Default IPv6 gateway address.
    interface string
    The VLAN raw device. See also name.
    mtu number
    The interface MTU.
    name string
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    timeoutReload number
    Timeout for network reload operations in seconds (defaults to 100).
    vlan number
    The VLAN tag. See also name.
    node_name str
    The name of the node.
    address str
    The interface IPv4/CIDR address.
    address6 str
    The interface IPv6/CIDR address.
    autostart bool
    Automatically start interface on boot (defaults to true).
    comment str
    Comment for the interface.
    gateway str
    Default gateway address.
    gateway6 str
    Default IPv6 gateway address.
    interface str
    The VLAN raw device. See also name.
    mtu int
    The interface MTU.
    name str
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    timeout_reload int
    Timeout for network reload operations in seconds (defaults to 100).
    vlan int
    The VLAN tag. See also name.
    nodeName String
    The name of the node.
    address String
    The interface IPv4/CIDR address.
    address6 String
    The interface IPv6/CIDR address.
    autostart Boolean
    Automatically start interface on boot (defaults to true).
    comment String
    Comment for the interface.
    gateway String
    Default gateway address.
    gateway6 String
    Default IPv6 gateway address.
    interface String
    The VLAN raw device. See also name.
    mtu Number
    The interface MTU.
    name String
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    timeoutReload Number
    Timeout for network reload operations in seconds (defaults to 100).
    vlan Number
    The VLAN tag. See also name.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the VlanLegacy resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing VlanLegacy Resource

    Get an existing VlanLegacy 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?: VlanLegacyState, opts?: CustomResourceOptions): VlanLegacy
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            address: Optional[str] = None,
            address6: Optional[str] = None,
            autostart: Optional[bool] = None,
            comment: Optional[str] = None,
            gateway: Optional[str] = None,
            gateway6: Optional[str] = None,
            interface: Optional[str] = None,
            mtu: Optional[int] = None,
            name: Optional[str] = None,
            node_name: Optional[str] = None,
            timeout_reload: Optional[int] = None,
            vlan: Optional[int] = None) -> VlanLegacy
    func GetVlanLegacy(ctx *Context, name string, id IDInput, state *VlanLegacyState, opts ...ResourceOption) (*VlanLegacy, error)
    public static VlanLegacy Get(string name, Input<string> id, VlanLegacyState? state, CustomResourceOptions? opts = null)
    public static VlanLegacy get(String name, Output<String> id, VlanLegacyState state, CustomResourceOptions options)
    resources:  _:    type: proxmoxve:network/linux/vlanLegacy:VlanLegacy    get:      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.
    The following state arguments are supported:
    Address string
    The interface IPv4/CIDR address.
    Address6 string
    The interface IPv6/CIDR address.
    Autostart bool
    Automatically start interface on boot (defaults to true).
    Comment string
    Comment for the interface.
    Gateway string
    Default gateway address.
    Gateway6 string
    Default IPv6 gateway address.
    Interface string
    The VLAN raw device. See also name.
    Mtu int
    The interface MTU.
    Name string
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    NodeName string
    The name of the node.
    TimeoutReload int
    Timeout for network reload operations in seconds (defaults to 100).
    vlanId int
    The VLAN tag. See also name.
    Address string
    The interface IPv4/CIDR address.
    Address6 string
    The interface IPv6/CIDR address.
    Autostart bool
    Automatically start interface on boot (defaults to true).
    Comment string
    Comment for the interface.
    Gateway string
    Default gateway address.
    Gateway6 string
    Default IPv6 gateway address.
    Interface string
    The VLAN raw device. See also name.
    Mtu int
    The interface MTU.
    Name string
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    NodeName string
    The name of the node.
    TimeoutReload int
    Timeout for network reload operations in seconds (defaults to 100).
    Vlan int
    The VLAN tag. See also name.
    address String
    The interface IPv4/CIDR address.
    address6 String
    The interface IPv6/CIDR address.
    autostart Boolean
    Automatically start interface on boot (defaults to true).
    comment String
    Comment for the interface.
    gateway String
    Default gateway address.
    gateway6 String
    Default IPv6 gateway address.
    interface_ String
    The VLAN raw device. See also name.
    mtu Integer
    The interface MTU.
    name String
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    nodeName String
    The name of the node.
    timeoutReload Integer
    Timeout for network reload operations in seconds (defaults to 100).
    vlan Integer
    The VLAN tag. See also name.
    address string
    The interface IPv4/CIDR address.
    address6 string
    The interface IPv6/CIDR address.
    autostart boolean
    Automatically start interface on boot (defaults to true).
    comment string
    Comment for the interface.
    gateway string
    Default gateway address.
    gateway6 string
    Default IPv6 gateway address.
    interface string
    The VLAN raw device. See also name.
    mtu number
    The interface MTU.
    name string
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    nodeName string
    The name of the node.
    timeoutReload number
    Timeout for network reload operations in seconds (defaults to 100).
    vlan number
    The VLAN tag. See also name.
    address str
    The interface IPv4/CIDR address.
    address6 str
    The interface IPv6/CIDR address.
    autostart bool
    Automatically start interface on boot (defaults to true).
    comment str
    Comment for the interface.
    gateway str
    Default gateway address.
    gateway6 str
    Default IPv6 gateway address.
    interface str
    The VLAN raw device. See also name.
    mtu int
    The interface MTU.
    name str
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    node_name str
    The name of the node.
    timeout_reload int
    Timeout for network reload operations in seconds (defaults to 100).
    vlan int
    The VLAN tag. See also name.
    address String
    The interface IPv4/CIDR address.
    address6 String
    The interface IPv6/CIDR address.
    autostart Boolean
    Automatically start interface on boot (defaults to true).
    comment String
    Comment for the interface.
    gateway String
    Default gateway address.
    gateway6 String
    Default IPv6 gateway address.
    interface String
    The VLAN raw device. See also name.
    mtu Number
    The interface MTU.
    name String
    The interface name. Either add the VLAN tag number to an existing interface name, e.g. ens18.21 (and do not set interface and vlan), or use custom name, e.g. vlanLab (interface and vlan are then required).
    nodeName String
    The name of the node.
    timeoutReload Number
    Timeout for network reload operations in seconds (defaults to 100).
    vlan Number
    The VLAN tag. See also name.

    Import

    !/usr/bin/env sh Interfaces can be imported using the node_name:iface format, e.g.

    $ pulumi import proxmoxve:network/linux/vlanLegacy:VlanLegacy vlan99 pve:vlan99
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    proxmoxve muhlba91/pulumi-proxmoxve
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the proxmox Terraform Provider.
    proxmoxve logo
    Viewing docs for Proxmox Virtual Environment (Proxmox VE) v8.0.0
    published on Sunday, Apr 5, 2026 by Daniel Muehlbachler-Pietrzykowski
      Try Pulumi Cloud free. Your team will thank you.