equinix.metal.Vlan
Explore with Pulumi AI
Provides a resource to allow users to manage Virtual Networks in their projects.
To learn more about Layer 2 networking in Equinix Metal, refer to
- https://metal.equinix.com/developers/docs/networking/layer2/
- https://metal.equinix.com/developers/docs/networking/layer2-configs/
Example Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Equinix = Pulumi.Equinix;
return await Deployment.RunAsync(() =>
{
var vlan1 = new Equinix.Metal.Vlan("vlan1", new()
{
Description = "VLAN in New Jersey",
Metro = "sv",
ProjectId = projectId,
Vxlan = 1040,
});
});
package main
import (
"github.com/equinix/pulumi-equinix/sdk/go/equinix/metal"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := metal.NewVlan(ctx, "vlan1", &metal.VlanArgs{
Description: pulumi.String("VLAN in New Jersey"),
Metro: pulumi.String("sv"),
ProjectId: pulumi.Any(projectId),
Vxlan: pulumi.Int(1040),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.equinix.metal.Vlan;
import com.pulumi.equinix.metal.VlanArgs;
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 vlan1 = new Vlan("vlan1", VlanArgs.builder()
.description("VLAN in New Jersey")
.metro("sv")
.projectId(projectId)
.vxlan(1040)
.build());
}
}
import pulumi
import pulumi_equinix as equinix
vlan1 = equinix.metal.Vlan("vlan1",
description="VLAN in New Jersey",
metro="sv",
project_id=project_id,
vxlan=1040)
import * as pulumi from "@pulumi/pulumi";
import * as equinix from "@equinix-labs/pulumi-equinix";
const vlan1 = new equinix.metal.Vlan("vlan1", {
description: "VLAN in New Jersey",
metro: "sv",
projectId: projectId,
vxlan: 1040,
});
resources:
# Create a new VLAN in metro "esv"
vlan1:
type: equinix:metal:Vlan
properties:
description: VLAN in New Jersey
metro: sv
projectId: ${projectId}
vxlan: 1040
Create Vlan Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Vlan(name: string, args: VlanArgs, opts?: CustomResourceOptions);
@overload
def Vlan(resource_name: str,
args: VlanArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Vlan(resource_name: str,
opts: Optional[ResourceOptions] = None,
project_id: Optional[str] = None,
description: Optional[str] = None,
facility: Optional[Union[str, Facility]] = None,
metro: Optional[str] = None,
vxlan: Optional[int] = None)
func NewVlan(ctx *Context, name string, args VlanArgs, opts ...ResourceOption) (*Vlan, error)
public Vlan(string name, VlanArgs args, CustomResourceOptions? opts = null)
type: equinix:metal:Vlan
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 VlanArgs
- 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 VlanArgs
- 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 VlanArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args VlanArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args VlanArgs
- 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 vlanResource = new Equinix.Metal.Vlan("vlanResource", new()
{
ProjectId = "string",
Description = "string",
Metro = "string",
Vxlan = 0,
});
example, err := metal.NewVlan(ctx, "vlanResource", &metal.VlanArgs{
ProjectId: pulumi.String("string"),
Description: pulumi.String("string"),
Metro: pulumi.String("string"),
Vxlan: pulumi.Int(0),
})
var vlanResource = new Vlan("vlanResource", VlanArgs.builder()
.projectId("string")
.description("string")
.metro("string")
.vxlan(0)
.build());
vlan_resource = equinix.metal.Vlan("vlanResource",
project_id="string",
description="string",
metro="string",
vxlan=0)
const vlanResource = new equinix.metal.Vlan("vlanResource", {
projectId: "string",
description: "string",
metro: "string",
vxlan: 0,
});
type: equinix:metal:Vlan
properties:
description: string
metro: string
projectId: string
vxlan: 0
Vlan 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 Vlan resource accepts the following input properties:
- Project
Id string - ID of parent project.
- Description string
- Description string.
- Facility
string | Pulumi.
Equinix. Metal. Facility - Facility where to create the VLAN. Use metro instead; read the facility to metro migration guide
- Metro string
- Metro in which to create the VLAN
- Vxlan int
- VLAN ID, must be unique in metro.
- project_
id str - ID of parent project.
- description str
- Description string.
- facility str | Facility
- Facility where to create the VLAN. Use metro instead; read the facility to metro migration guide
- metro str
- Metro in which to create the VLAN
- vxlan int
- VLAN ID, must be unique in metro.
- project
Id String - ID of parent project.
- description String
- Description string.
- facility String | "am2" | "am6" | "ma5" | "nrt1" | "pa4" | "sk2" | "me2" | "hk2" | "ty11" | "la4" | "da6" | "da11" | "da3" | "sp4" | "mt1" | "sv16" | "sjc1" | "fra2" | "fr8" | "ny5" | "ny6" | "ny7" | "ch3" | "sl1" | "sy5" | "os3" | "ld7" | "dc10" | "ams1" | "sg4" | "se4" | "sy4" | "at4" | "dfw2" | "tr2" | "dc13" | "he7" | "ewr1" | "sg5" | "sg1" | "md2" | "sv15"
- Facility where to create the VLAN. Use metro instead; read the facility to metro migration guide
- metro String
- Metro in which to create the VLAN
- vxlan Number
- VLAN ID, must be unique in metro.
Outputs
All input properties are implicitly available as output properties. Additionally, the Vlan 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 Vlan Resource
Get an existing Vlan 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?: VlanState, opts?: CustomResourceOptions): Vlan
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
description: Optional[str] = None,
facility: Optional[Union[str, Facility]] = None,
metro: Optional[str] = None,
project_id: Optional[str] = None,
vxlan: Optional[int] = None) -> Vlan
func GetVlan(ctx *Context, name string, id IDInput, state *VlanState, opts ...ResourceOption) (*Vlan, error)
public static Vlan Get(string name, Input<string> id, VlanState? state, CustomResourceOptions? opts = null)
public static Vlan get(String name, Output<String> id, VlanState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- 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.
- Description string
- Description string.
- Facility
string | Pulumi.
Equinix. Metal. Facility - Facility where to create the VLAN. Use metro instead; read the facility to metro migration guide
- Metro string
- Metro in which to create the VLAN
- Project
Id string - ID of parent project.
- Vxlan int
- VLAN ID, must be unique in metro.
- description str
- Description string.
- facility str | Facility
- Facility where to create the VLAN. Use metro instead; read the facility to metro migration guide
- metro str
- Metro in which to create the VLAN
- project_
id str - ID of parent project.
- vxlan int
- VLAN ID, must be unique in metro.
- description String
- Description string.
- facility String | "am2" | "am6" | "ma5" | "nrt1" | "pa4" | "sk2" | "me2" | "hk2" | "ty11" | "la4" | "da6" | "da11" | "da3" | "sp4" | "mt1" | "sv16" | "sjc1" | "fra2" | "fr8" | "ny5" | "ny6" | "ny7" | "ch3" | "sl1" | "sy5" | "os3" | "ld7" | "dc10" | "ams1" | "sg4" | "se4" | "sy4" | "at4" | "dfw2" | "tr2" | "dc13" | "he7" | "ewr1" | "sg5" | "sg1" | "md2" | "sv15"
- Facility where to create the VLAN. Use metro instead; read the facility to metro migration guide
- metro String
- Metro in which to create the VLAN
- project
Id String - ID of parent project.
- vxlan Number
- VLAN ID, must be unique in metro.
Supporting Types
Facility, FacilityArgs
- AM2
- am2Amsterdam 2
- AM6
- am6Amsterdam 6
- MA5
- ma5Manchester 5
- NRT1
- nrt1Tokio 1
- PA4
- pa4Paris 4
- SK2
- sk2Stockholm 2
- ME2
- me2Melbourne 2
- HK2
- hk2Hong Kong 2
- TY11
- ty11Tokyo 11
- LA4
- la4Los Angeles 4
- DA6
- da6Dallas 6
- DA11
- da11Dallas 11
- DA3
- da3Dallas 3
- SP4
- sp4Sao Paulo 4
- MT1
- mt1Montreal 1
- SV16
- sv16Silicon Valley 16
- SJC1
- sjc1Sunnyvale, CA 1
- FRA2
- fra2Frankfurt 2
- FRA8
- fr8Frankfurt 8
- NY5
- ny5New York 5
- NY6
- ny6New York 6
- NY7
- ny7New York 7
- CH3
- ch3Chicago 3
- SL1
- sl1Seoul 1
- SY5
- sy5Sydney 5
- OS3
- os3Osaka 3
- LD7
- ld7London 7
- DC10
- dc10Washington DC 10
- AMS1
- ams1Amsterdam 1
- SG4
- sg4Singapore 4
- SE4
- se4Seattle 4
- SY4
- sy4Sydney 4
- AT4
- at4Atlanta 4
- DFW2
- dfw2Dallas 2
- TR2
- tr2Toronto
- DC13
- dc13Washington DC
- HE7
- he7Helsinki
- EWR1
- ewr1Parsippany, NJ 1
- SG5
- sg5Singapore 5
- SG1
- sg1Singapore 1
- MD2
- md2Madrid 2
- SV15
- sv15Silicon Valley 15
- Facility
AM2 - am2Amsterdam 2
- Facility
AM6 - am6Amsterdam 6
- Facility
MA5 - ma5Manchester 5
- Facility
NRT1 - nrt1Tokio 1
- Facility
PA4 - pa4Paris 4
- Facility
SK2 - sk2Stockholm 2
- Facility
ME2 - me2Melbourne 2
- Facility
HK2 - hk2Hong Kong 2
- Facility
TY11 - ty11Tokyo 11
- Facility
LA4 - la4Los Angeles 4
- Facility
DA6 - da6Dallas 6
- Facility
DA11 - da11Dallas 11
- Facility
DA3 - da3Dallas 3
- Facility
SP4 - sp4Sao Paulo 4
- Facility
MT1 - mt1Montreal 1
- Facility
SV16 - sv16Silicon Valley 16
- Facility
SJC1 - sjc1Sunnyvale, CA 1
- Facility
FRA2 - fra2Frankfurt 2
- Facility
FRA8 - fr8Frankfurt 8
- Facility
NY5 - ny5New York 5
- Facility
NY6 - ny6New York 6
- Facility
NY7 - ny7New York 7
- Facility
CH3 - ch3Chicago 3
- Facility
SL1 - sl1Seoul 1
- Facility
SY5 - sy5Sydney 5
- Facility
OS3 - os3Osaka 3
- Facility
LD7 - ld7London 7
- Facility
DC10 - dc10Washington DC 10
- Facility
AMS1 - ams1Amsterdam 1
- Facility
SG4 - sg4Singapore 4
- Facility
SE4 - se4Seattle 4
- Facility
SY4 - sy4Sydney 4
- Facility
AT4 - at4Atlanta 4
- Facility
DFW2 - dfw2Dallas 2
- Facility
TR2 - tr2Toronto
- Facility
DC13 - dc13Washington DC
- Facility
HE7 - he7Helsinki
- Facility
EWR1 - ewr1Parsippany, NJ 1
- Facility
SG5 - sg5Singapore 5
- Facility
SG1 - sg1Singapore 1
- Facility
MD2 - md2Madrid 2
- Facility
SV15 - sv15Silicon Valley 15
- AM2
- am2Amsterdam 2
- AM6
- am6Amsterdam 6
- MA5
- ma5Manchester 5
- NRT1
- nrt1Tokio 1
- PA4
- pa4Paris 4
- SK2
- sk2Stockholm 2
- ME2
- me2Melbourne 2
- HK2
- hk2Hong Kong 2
- TY11
- ty11Tokyo 11
- LA4
- la4Los Angeles 4
- DA6
- da6Dallas 6
- DA11
- da11Dallas 11
- DA3
- da3Dallas 3
- SP4
- sp4Sao Paulo 4
- MT1
- mt1Montreal 1
- SV16
- sv16Silicon Valley 16
- SJC1
- sjc1Sunnyvale, CA 1
- FRA2
- fra2Frankfurt 2
- FRA8
- fr8Frankfurt 8
- NY5
- ny5New York 5
- NY6
- ny6New York 6
- NY7
- ny7New York 7
- CH3
- ch3Chicago 3
- SL1
- sl1Seoul 1
- SY5
- sy5Sydney 5
- OS3
- os3Osaka 3
- LD7
- ld7London 7
- DC10
- dc10Washington DC 10
- AMS1
- ams1Amsterdam 1
- SG4
- sg4Singapore 4
- SE4
- se4Seattle 4
- SY4
- sy4Sydney 4
- AT4
- at4Atlanta 4
- DFW2
- dfw2Dallas 2
- TR2
- tr2Toronto
- DC13
- dc13Washington DC
- HE7
- he7Helsinki
- EWR1
- ewr1Parsippany, NJ 1
- SG5
- sg5Singapore 5
- SG1
- sg1Singapore 1
- MD2
- md2Madrid 2
- SV15
- sv15Silicon Valley 15
- AM2
- am2Amsterdam 2
- AM6
- am6Amsterdam 6
- MA5
- ma5Manchester 5
- NRT1
- nrt1Tokio 1
- PA4
- pa4Paris 4
- SK2
- sk2Stockholm 2
- ME2
- me2Melbourne 2
- HK2
- hk2Hong Kong 2
- TY11
- ty11Tokyo 11
- LA4
- la4Los Angeles 4
- DA6
- da6Dallas 6
- DA11
- da11Dallas 11
- DA3
- da3Dallas 3
- SP4
- sp4Sao Paulo 4
- MT1
- mt1Montreal 1
- SV16
- sv16Silicon Valley 16
- SJC1
- sjc1Sunnyvale, CA 1
- FRA2
- fra2Frankfurt 2
- FRA8
- fr8Frankfurt 8
- NY5
- ny5New York 5
- NY6
- ny6New York 6
- NY7
- ny7New York 7
- CH3
- ch3Chicago 3
- SL1
- sl1Seoul 1
- SY5
- sy5Sydney 5
- OS3
- os3Osaka 3
- LD7
- ld7London 7
- DC10
- dc10Washington DC 10
- AMS1
- ams1Amsterdam 1
- SG4
- sg4Singapore 4
- SE4
- se4Seattle 4
- SY4
- sy4Sydney 4
- AT4
- at4Atlanta 4
- DFW2
- dfw2Dallas 2
- TR2
- tr2Toronto
- DC13
- dc13Washington DC
- HE7
- he7Helsinki
- EWR1
- ewr1Parsippany, NJ 1
- SG5
- sg5Singapore 5
- SG1
- sg1Singapore 1
- MD2
- md2Madrid 2
- SV15
- sv15Silicon Valley 15
- AM2
- am2Amsterdam 2
- AM6
- am6Amsterdam 6
- MA5
- ma5Manchester 5
- NRT1
- nrt1Tokio 1
- PA4
- pa4Paris 4
- SK2
- sk2Stockholm 2
- ME2
- me2Melbourne 2
- HK2
- hk2Hong Kong 2
- TY11
- ty11Tokyo 11
- LA4
- la4Los Angeles 4
- DA6
- da6Dallas 6
- DA11
- da11Dallas 11
- DA3
- da3Dallas 3
- SP4
- sp4Sao Paulo 4
- MT1
- mt1Montreal 1
- SV16
- sv16Silicon Valley 16
- SJC1
- sjc1Sunnyvale, CA 1
- FRA2
- fra2Frankfurt 2
- FRA8
- fr8Frankfurt 8
- NY5
- ny5New York 5
- NY6
- ny6New York 6
- NY7
- ny7New York 7
- CH3
- ch3Chicago 3
- SL1
- sl1Seoul 1
- SY5
- sy5Sydney 5
- OS3
- os3Osaka 3
- LD7
- ld7London 7
- DC10
- dc10Washington DC 10
- AMS1
- ams1Amsterdam 1
- SG4
- sg4Singapore 4
- SE4
- se4Seattle 4
- SY4
- sy4Sydney 4
- AT4
- at4Atlanta 4
- DFW2
- dfw2Dallas 2
- TR2
- tr2Toronto
- DC13
- dc13Washington DC
- HE7
- he7Helsinki
- EWR1
- ewr1Parsippany, NJ 1
- SG5
- sg5Singapore 5
- SG1
- sg1Singapore 1
- MD2
- md2Madrid 2
- SV15
- sv15Silicon Valley 15
- "am2"
- am2Amsterdam 2
- "am6"
- am6Amsterdam 6
- "ma5"
- ma5Manchester 5
- "nrt1"
- nrt1Tokio 1
- "pa4"
- pa4Paris 4
- "sk2"
- sk2Stockholm 2
- "me2"
- me2Melbourne 2
- "hk2"
- hk2Hong Kong 2
- "ty11"
- ty11Tokyo 11
- "la4"
- la4Los Angeles 4
- "da6"
- da6Dallas 6
- "da11"
- da11Dallas 11
- "da3"
- da3Dallas 3
- "sp4"
- sp4Sao Paulo 4
- "mt1"
- mt1Montreal 1
- "sv16"
- sv16Silicon Valley 16
- "sjc1"
- sjc1Sunnyvale, CA 1
- "fra2"
- fra2Frankfurt 2
- "fr8"
- fr8Frankfurt 8
- "ny5"
- ny5New York 5
- "ny6"
- ny6New York 6
- "ny7"
- ny7New York 7
- "ch3"
- ch3Chicago 3
- "sl1"
- sl1Seoul 1
- "sy5"
- sy5Sydney 5
- "os3"
- os3Osaka 3
- "ld7"
- ld7London 7
- "dc10"
- dc10Washington DC 10
- "ams1"
- ams1Amsterdam 1
- "sg4"
- sg4Singapore 4
- "se4"
- se4Seattle 4
- "sy4"
- sy4Sydney 4
- "at4"
- at4Atlanta 4
- "dfw2"
- dfw2Dallas 2
- "tr2"
- tr2Toronto
- "dc13"
- dc13Washington DC
- "he7"
- he7Helsinki
- "ewr1"
- ewr1Parsippany, NJ 1
- "sg5"
- sg5Singapore 5
- "sg1"
- sg1Singapore 1
- "md2"
- md2Madrid 2
- "sv15"
- sv15Silicon Valley 15
Package Details
- Repository
- equinix equinix/pulumi-equinix
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
equinix
Terraform Provider.