1. Packages
  2. Nsxt Provider
  3. API Docs
  4. PolicyL2VpnSession
nsxt 3.8.1 published on Wednesday, Apr 30, 2025 by vmware

nsxt.PolicyL2VpnSession

Explore with Pulumi AI

nsxt logo
nsxt 3.8.1 published on Wednesday, Apr 30, 2025 by vmware

    This resource provides a method for the management of a L2VPN VPN session.

    This resource is applicable to NSX Policy Manager and VMC.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as nsxt from "@pulumi/nsxt";
    
    const test = new nsxt.PolicyL2VpnSession("test", {
        displayName: "L2 VPN Session",
        description: "Terraform-provisioned L2 VPN Tunnel",
        servicePath: nsxt_policy_l2_vpn_service.test.path,
        transportTunnels: [nsxt_policy_ipsec_vpn_session.ipsec_vpn_session_for_l2vpn.path],
    });
    
    import pulumi
    import pulumi_nsxt as nsxt
    
    test = nsxt.PolicyL2VpnSession("test",
        display_name="L2 VPN Session",
        description="Terraform-provisioned L2 VPN Tunnel",
        service_path=nsxt_policy_l2_vpn_service["test"]["path"],
        transport_tunnels=[nsxt_policy_ipsec_vpn_session["ipsec_vpn_session_for_l2vpn"]["path"]])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/nsxt/v3/nsxt"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := nsxt.NewPolicyL2VpnSession(ctx, "test", &nsxt.PolicyL2VpnSessionArgs{
    			DisplayName: pulumi.String("L2 VPN Session"),
    			Description: pulumi.String("Terraform-provisioned L2 VPN Tunnel"),
    			ServicePath: pulumi.Any(nsxt_policy_l2_vpn_service.Test.Path),
    			TransportTunnels: pulumi.StringArray{
    				nsxt_policy_ipsec_vpn_session.Ipsec_vpn_session_for_l2vpn.Path,
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Nsxt = Pulumi.Nsxt;
    
    return await Deployment.RunAsync(() => 
    {
        var test = new Nsxt.PolicyL2VpnSession("test", new()
        {
            DisplayName = "L2 VPN Session",
            Description = "Terraform-provisioned L2 VPN Tunnel",
            ServicePath = nsxt_policy_l2_vpn_service.Test.Path,
            TransportTunnels = new[]
            {
                nsxt_policy_ipsec_vpn_session.Ipsec_vpn_session_for_l2vpn.Path,
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.nsxt.PolicyL2VpnSession;
    import com.pulumi.nsxt.PolicyL2VpnSessionArgs;
    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 PolicyL2VpnSession("test", PolicyL2VpnSessionArgs.builder()
                .displayName("L2 VPN Session")
                .description("Terraform-provisioned L2 VPN Tunnel")
                .servicePath(nsxt_policy_l2_vpn_service.test().path())
                .transportTunnels(nsxt_policy_ipsec_vpn_session.ipsec_vpn_session_for_l2vpn().path())
                .build());
    
        }
    }
    
    resources:
      test:
        type: nsxt:PolicyL2VpnSession
        properties:
          displayName: L2 VPN Session
          description: Terraform-provisioned L2 VPN Tunnel
          servicePath: ${nsxt_policy_l2_vpn_service.test.path}
          transportTunnels:
            - ${nsxt_policy_ipsec_vpn_session.ipsec_vpn_session_for_l2vpn.path}
    

    Create PolicyL2VpnSession Resource

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

    Constructor syntax

    new PolicyL2VpnSession(name: string, args: PolicyL2VpnSessionArgs, opts?: CustomResourceOptions);
    @overload
    def PolicyL2VpnSession(resource_name: str,
                           args: PolicyL2VpnSessionArgs,
                           opts: Optional[ResourceOptions] = None)
    
    @overload
    def PolicyL2VpnSession(resource_name: str,
                           opts: Optional[ResourceOptions] = None,
                           service_path: Optional[str] = None,
                           transport_tunnels: Optional[Sequence[str]] = None,
                           display_name: Optional[str] = None,
                           nsx_id: Optional[str] = None,
                           local_address: Optional[str] = None,
                           max_segment_size: Optional[float] = None,
                           description: Optional[str] = None,
                           peer_address: Optional[str] = None,
                           policy_l2_vpn_session_id: Optional[str] = None,
                           protocol: Optional[str] = None,
                           enabled: Optional[bool] = None,
                           tags: Optional[Sequence[PolicyL2VpnSessionTagArgs]] = None,
                           direction: Optional[str] = None)
    func NewPolicyL2VpnSession(ctx *Context, name string, args PolicyL2VpnSessionArgs, opts ...ResourceOption) (*PolicyL2VpnSession, error)
    public PolicyL2VpnSession(string name, PolicyL2VpnSessionArgs args, CustomResourceOptions? opts = null)
    public PolicyL2VpnSession(String name, PolicyL2VpnSessionArgs args)
    public PolicyL2VpnSession(String name, PolicyL2VpnSessionArgs args, CustomResourceOptions options)
    
    type: nsxt:PolicyL2VpnSession
    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 PolicyL2VpnSessionArgs
    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 PolicyL2VpnSessionArgs
    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 PolicyL2VpnSessionArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args PolicyL2VpnSessionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args PolicyL2VpnSessionArgs
    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 policyL2VpnSessionResource = new Nsxt.PolicyL2VpnSession("policyL2VpnSessionResource", new()
    {
        ServicePath = "string",
        TransportTunnels = new[]
        {
            "string",
        },
        DisplayName = "string",
        NsxId = "string",
        LocalAddress = "string",
        MaxSegmentSize = 0,
        Description = "string",
        PeerAddress = "string",
        PolicyL2VpnSessionId = "string",
        Protocol = "string",
        Enabled = false,
        Tags = new[]
        {
            new Nsxt.Inputs.PolicyL2VpnSessionTagArgs
            {
                Scope = "string",
                Tag = "string",
            },
        },
        Direction = "string",
    });
    
    example, err := nsxt.NewPolicyL2VpnSession(ctx, "policyL2VpnSessionResource", &nsxt.PolicyL2VpnSessionArgs{
    	ServicePath: pulumi.String("string"),
    	TransportTunnels: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	DisplayName:          pulumi.String("string"),
    	NsxId:                pulumi.String("string"),
    	LocalAddress:         pulumi.String("string"),
    	MaxSegmentSize:       pulumi.Float64(0),
    	Description:          pulumi.String("string"),
    	PeerAddress:          pulumi.String("string"),
    	PolicyL2VpnSessionId: pulumi.String("string"),
    	Protocol:             pulumi.String("string"),
    	Enabled:              pulumi.Bool(false),
    	Tags: nsxt.PolicyL2VpnSessionTagArray{
    		&nsxt.PolicyL2VpnSessionTagArgs{
    			Scope: pulumi.String("string"),
    			Tag:   pulumi.String("string"),
    		},
    	},
    	Direction: pulumi.String("string"),
    })
    
    var policyL2VpnSessionResource = new PolicyL2VpnSession("policyL2VpnSessionResource", PolicyL2VpnSessionArgs.builder()
        .servicePath("string")
        .transportTunnels("string")
        .displayName("string")
        .nsxId("string")
        .localAddress("string")
        .maxSegmentSize(0)
        .description("string")
        .peerAddress("string")
        .policyL2VpnSessionId("string")
        .protocol("string")
        .enabled(false)
        .tags(PolicyL2VpnSessionTagArgs.builder()
            .scope("string")
            .tag("string")
            .build())
        .direction("string")
        .build());
    
    policy_l2_vpn_session_resource = nsxt.PolicyL2VpnSession("policyL2VpnSessionResource",
        service_path="string",
        transport_tunnels=["string"],
        display_name="string",
        nsx_id="string",
        local_address="string",
        max_segment_size=0,
        description="string",
        peer_address="string",
        policy_l2_vpn_session_id="string",
        protocol="string",
        enabled=False,
        tags=[{
            "scope": "string",
            "tag": "string",
        }],
        direction="string")
    
    const policyL2VpnSessionResource = new nsxt.PolicyL2VpnSession("policyL2VpnSessionResource", {
        servicePath: "string",
        transportTunnels: ["string"],
        displayName: "string",
        nsxId: "string",
        localAddress: "string",
        maxSegmentSize: 0,
        description: "string",
        peerAddress: "string",
        policyL2VpnSessionId: "string",
        protocol: "string",
        enabled: false,
        tags: [{
            scope: "string",
            tag: "string",
        }],
        direction: "string",
    });
    
    type: nsxt:PolicyL2VpnSession
    properties:
        description: string
        direction: string
        displayName: string
        enabled: false
        localAddress: string
        maxSegmentSize: 0
        nsxId: string
        peerAddress: string
        policyL2VpnSessionId: string
        protocol: string
        servicePath: string
        tags:
            - scope: string
              tag: string
        transportTunnels:
            - string
    

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

    DisplayName string
    Display name of the resource.
    ServicePath string
    The path of the L2 VPN service for the VPN session.
    TransportTunnels List<string>
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    Description string
    Description of the resource.
    Direction string
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    Enabled bool
    Enable/Disable IPSec VPN session.
    LocalAddress string
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    MaxSegmentSize double
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    NsxId string
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    PeerAddress string
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    PolicyL2VpnSessionId string
    ID of the resource.
    Protocol string
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    Tags List<PolicyL2VpnSessionTag>
    A list of scope + tag pairs to associate with this resource.
    DisplayName string
    Display name of the resource.
    ServicePath string
    The path of the L2 VPN service for the VPN session.
    TransportTunnels []string
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    Description string
    Description of the resource.
    Direction string
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    Enabled bool
    Enable/Disable IPSec VPN session.
    LocalAddress string
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    MaxSegmentSize float64
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    NsxId string
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    PeerAddress string
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    PolicyL2VpnSessionId string
    ID of the resource.
    Protocol string
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    Tags []PolicyL2VpnSessionTagArgs
    A list of scope + tag pairs to associate with this resource.
    displayName String
    Display name of the resource.
    servicePath String
    The path of the L2 VPN service for the VPN session.
    transportTunnels List<String>
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    description String
    Description of the resource.
    direction String
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    enabled Boolean
    Enable/Disable IPSec VPN session.
    localAddress String
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    maxSegmentSize Double
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    nsxId String
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    peerAddress String
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    policyL2VpnSessionId String
    ID of the resource.
    protocol String
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    tags List<PolicyL2VpnSessionTag>
    A list of scope + tag pairs to associate with this resource.
    displayName string
    Display name of the resource.
    servicePath string
    The path of the L2 VPN service for the VPN session.
    transportTunnels string[]
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    description string
    Description of the resource.
    direction string
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    enabled boolean
    Enable/Disable IPSec VPN session.
    localAddress string
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    maxSegmentSize number
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    nsxId string
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    peerAddress string
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    policyL2VpnSessionId string
    ID of the resource.
    protocol string
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    tags PolicyL2VpnSessionTag[]
    A list of scope + tag pairs to associate with this resource.
    display_name str
    Display name of the resource.
    service_path str
    The path of the L2 VPN service for the VPN session.
    transport_tunnels Sequence[str]
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    description str
    Description of the resource.
    direction str
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    enabled bool
    Enable/Disable IPSec VPN session.
    local_address str
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    max_segment_size float
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    nsx_id str
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    peer_address str
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    policy_l2_vpn_session_id str
    ID of the resource.
    protocol str
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    tags Sequence[PolicyL2VpnSessionTagArgs]
    A list of scope + tag pairs to associate with this resource.
    displayName String
    Display name of the resource.
    servicePath String
    The path of the L2 VPN service for the VPN session.
    transportTunnels List<String>
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    description String
    Description of the resource.
    direction String
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    enabled Boolean
    Enable/Disable IPSec VPN session.
    localAddress String
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    maxSegmentSize Number
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    nsxId String
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    peerAddress String
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    policyL2VpnSessionId String
    ID of the resource.
    protocol String
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    tags List<Property Map>
    A list of scope + tag pairs to associate with this resource.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Path string
    The NSX path of the policy resource.
    Revision double
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    Id string
    The provider-assigned unique ID for this managed resource.
    Path string
    The NSX path of the policy resource.
    Revision float64
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    id String
    The provider-assigned unique ID for this managed resource.
    path String
    The NSX path of the policy resource.
    revision Double
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    id string
    The provider-assigned unique ID for this managed resource.
    path string
    The NSX path of the policy resource.
    revision number
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    id str
    The provider-assigned unique ID for this managed resource.
    path str
    The NSX path of the policy resource.
    revision float
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    id String
    The provider-assigned unique ID for this managed resource.
    path String
    The NSX path of the policy resource.
    revision Number
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.

    Look up Existing PolicyL2VpnSession Resource

    Get an existing PolicyL2VpnSession 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?: PolicyL2VpnSessionState, opts?: CustomResourceOptions): PolicyL2VpnSession
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            description: Optional[str] = None,
            direction: Optional[str] = None,
            display_name: Optional[str] = None,
            enabled: Optional[bool] = None,
            local_address: Optional[str] = None,
            max_segment_size: Optional[float] = None,
            nsx_id: Optional[str] = None,
            path: Optional[str] = None,
            peer_address: Optional[str] = None,
            policy_l2_vpn_session_id: Optional[str] = None,
            protocol: Optional[str] = None,
            revision: Optional[float] = None,
            service_path: Optional[str] = None,
            tags: Optional[Sequence[PolicyL2VpnSessionTagArgs]] = None,
            transport_tunnels: Optional[Sequence[str]] = None) -> PolicyL2VpnSession
    func GetPolicyL2VpnSession(ctx *Context, name string, id IDInput, state *PolicyL2VpnSessionState, opts ...ResourceOption) (*PolicyL2VpnSession, error)
    public static PolicyL2VpnSession Get(string name, Input<string> id, PolicyL2VpnSessionState? state, CustomResourceOptions? opts = null)
    public static PolicyL2VpnSession get(String name, Output<String> id, PolicyL2VpnSessionState state, CustomResourceOptions options)
    resources:  _:    type: nsxt:PolicyL2VpnSession    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:
    Description string
    Description of the resource.
    Direction string
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    DisplayName string
    Display name of the resource.
    Enabled bool
    Enable/Disable IPSec VPN session.
    LocalAddress string
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    MaxSegmentSize double
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    NsxId string
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    Path string
    The NSX path of the policy resource.
    PeerAddress string
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    PolicyL2VpnSessionId string
    ID of the resource.
    Protocol string
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    Revision double
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    ServicePath string
    The path of the L2 VPN service for the VPN session.
    Tags List<PolicyL2VpnSessionTag>
    A list of scope + tag pairs to associate with this resource.
    TransportTunnels List<string>
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    Description string
    Description of the resource.
    Direction string
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    DisplayName string
    Display name of the resource.
    Enabled bool
    Enable/Disable IPSec VPN session.
    LocalAddress string
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    MaxSegmentSize float64
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    NsxId string
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    Path string
    The NSX path of the policy resource.
    PeerAddress string
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    PolicyL2VpnSessionId string
    ID of the resource.
    Protocol string
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    Revision float64
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    ServicePath string
    The path of the L2 VPN service for the VPN session.
    Tags []PolicyL2VpnSessionTagArgs
    A list of scope + tag pairs to associate with this resource.
    TransportTunnels []string
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    description String
    Description of the resource.
    direction String
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    displayName String
    Display name of the resource.
    enabled Boolean
    Enable/Disable IPSec VPN session.
    localAddress String
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    maxSegmentSize Double
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    nsxId String
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    path String
    The NSX path of the policy resource.
    peerAddress String
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    policyL2VpnSessionId String
    ID of the resource.
    protocol String
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    revision Double
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    servicePath String
    The path of the L2 VPN service for the VPN session.
    tags List<PolicyL2VpnSessionTag>
    A list of scope + tag pairs to associate with this resource.
    transportTunnels List<String>
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    description string
    Description of the resource.
    direction string
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    displayName string
    Display name of the resource.
    enabled boolean
    Enable/Disable IPSec VPN session.
    localAddress string
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    maxSegmentSize number
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    nsxId string
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    path string
    The NSX path of the policy resource.
    peerAddress string
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    policyL2VpnSessionId string
    ID of the resource.
    protocol string
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    revision number
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    servicePath string
    The path of the L2 VPN service for the VPN session.
    tags PolicyL2VpnSessionTag[]
    A list of scope + tag pairs to associate with this resource.
    transportTunnels string[]
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    description str
    Description of the resource.
    direction str
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    display_name str
    Display name of the resource.
    enabled bool
    Enable/Disable IPSec VPN session.
    local_address str
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    max_segment_size float
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    nsx_id str
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    path str
    The NSX path of the policy resource.
    peer_address str
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    policy_l2_vpn_session_id str
    ID of the resource.
    protocol str
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    revision float
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    service_path str
    The path of the L2 VPN service for the VPN session.
    tags Sequence[PolicyL2VpnSessionTagArgs]
    A list of scope + tag pairs to associate with this resource.
    transport_tunnels Sequence[str]
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.
    description String
    Description of the resource.
    direction String
    The traffic direction apply to the MSS clamping. BOTH or NONE.
    displayName String
    Display name of the resource.
    enabled Boolean
    Enable/Disable IPSec VPN session.
    localAddress String
    IP Address of the local tunnel port. This property only applies in CLIENT mode.
    maxSegmentSize Number
    Maximum amount of data the host will accept in a TCP segment. Value should be between 108 and 8860. If not specified then the value would be the automatic calculated MSS value.
    nsxId String
    The NSX ID of this resource. If set, this ID will be used to create the resource.
    path String
    The NSX path of the policy resource.
    peerAddress String
    IP Address of the peer tunnel port. This property only applies in CLIENT mode.
    policyL2VpnSessionId String
    ID of the resource.
    protocol String
    Encapsulation protocol used by the tunnel. GRE is the only supported value.
    revision Number
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    servicePath String
    The path of the L2 VPN service for the VPN session.
    tags List<Property Map>
    A list of scope + tag pairs to associate with this resource.
    transportTunnels List<String>
    List of transport tunnels paths for redundancy. L2VPN supports only AES_GCM_128 encryption algorithm for IPSec tunnel profile.

    Supporting Types

    PolicyL2VpnSessionTag, PolicyL2VpnSessionTagArgs

    Scope string
    Tag string
    A list of scope + tag pairs to associate with this resource.
    Scope string
    Tag string
    A list of scope + tag pairs to associate with this resource.
    scope String
    tag String
    A list of scope + tag pairs to associate with this resource.
    scope string
    tag string
    A list of scope + tag pairs to associate with this resource.
    scope str
    tag str
    A list of scope + tag pairs to associate with this resource.
    scope String
    tag String
    A list of scope + tag pairs to associate with this resource.

    Import

    ing

    An existing object can be imported into this resource, via the following command:

    terraform import nsxt_policy_l2_vpn_session.test UUID
    

    The above command imports L2 VPN session named test with the NSX ID UUID.

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

    Package Details

    Repository
    nsxt vmware/terraform-provider-nsxt
    License
    Notes
    This Pulumi package is based on the nsxt Terraform Provider.
    nsxt logo
    nsxt 3.8.1 published on Wednesday, Apr 30, 2025 by vmware