edgecenter.Network
Explore with Pulumi AI
Represent network. A network is a software-defined network in a cloud computing infrastructure
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as edgecenter from "@pulumi/edgecenter";
const network = new edgecenter.Network("network", {
projectId: 1,
regionId: 1,
type: "vxlan",
});
import pulumi
import pulumi_edgecenter as edgecenter
network = edgecenter.Network("network",
project_id=1,
region_id=1,
type="vxlan")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/edgecenter/edgecenter"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := edgecenter.NewNetwork(ctx, "network", &edgecenter.NetworkArgs{
ProjectId: pulumi.Float64(1),
RegionId: pulumi.Float64(1),
Type: pulumi.String("vxlan"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Edgecenter = Pulumi.Edgecenter;
return await Deployment.RunAsync(() =>
{
var network = new Edgecenter.Network("network", new()
{
ProjectId = 1,
RegionId = 1,
Type = "vxlan",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.edgecenter.Network;
import com.pulumi.edgecenter.NetworkArgs;
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 network = new Network("network", NetworkArgs.builder()
.projectId(1)
.regionId(1)
.type("vxlan")
.build());
}
}
resources:
network:
type: edgecenter:Network
properties:
projectId: 1
regionId: 1
type: vxlan
Create Network Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Network(name: string, args?: NetworkArgs, opts?: CustomResourceOptions);
@overload
def Network(resource_name: str,
args: Optional[NetworkArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def Network(resource_name: str,
opts: Optional[ResourceOptions] = None,
create_router: Optional[bool] = None,
last_updated: Optional[str] = None,
metadata_map: Optional[Mapping[str, str]] = None,
name: Optional[str] = None,
network_id: Optional[str] = None,
project_id: Optional[float] = None,
project_name: Optional[str] = None,
region_id: Optional[float] = None,
region_name: Optional[str] = None,
type: Optional[str] = None)
func NewNetwork(ctx *Context, name string, args *NetworkArgs, opts ...ResourceOption) (*Network, error)
public Network(string name, NetworkArgs? args = null, CustomResourceOptions? opts = null)
public Network(String name, NetworkArgs args)
public Network(String name, NetworkArgs args, CustomResourceOptions options)
type: edgecenter:Network
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 NetworkArgs
- 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 NetworkArgs
- 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 NetworkArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args NetworkArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args NetworkArgs
- 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 networkResource = new Edgecenter.Network("networkResource", new()
{
CreateRouter = false,
LastUpdated = "string",
MetadataMap =
{
{ "string", "string" },
},
Name = "string",
NetworkId = "string",
ProjectId = 0,
ProjectName = "string",
RegionId = 0,
RegionName = "string",
Type = "string",
});
example, err := edgecenter.NewNetwork(ctx, "networkResource", &edgecenter.NetworkArgs{
CreateRouter: pulumi.Bool(false),
LastUpdated: pulumi.String("string"),
MetadataMap: pulumi.StringMap{
"string": pulumi.String("string"),
},
Name: pulumi.String("string"),
NetworkId: pulumi.String("string"),
ProjectId: pulumi.Float64(0),
ProjectName: pulumi.String("string"),
RegionId: pulumi.Float64(0),
RegionName: pulumi.String("string"),
Type: pulumi.String("string"),
})
var networkResource = new Network("networkResource", NetworkArgs.builder()
.createRouter(false)
.lastUpdated("string")
.metadataMap(Map.of("string", "string"))
.name("string")
.networkId("string")
.projectId(0)
.projectName("string")
.regionId(0)
.regionName("string")
.type("string")
.build());
network_resource = edgecenter.Network("networkResource",
create_router=False,
last_updated="string",
metadata_map={
"string": "string",
},
name="string",
network_id="string",
project_id=0,
project_name="string",
region_id=0,
region_name="string",
type="string")
const networkResource = new edgecenter.Network("networkResource", {
createRouter: false,
lastUpdated: "string",
metadataMap: {
string: "string",
},
name: "string",
networkId: "string",
projectId: 0,
projectName: "string",
regionId: 0,
regionName: "string",
type: "string",
});
type: edgecenter:Network
properties:
createRouter: false
lastUpdated: string
metadataMap:
string: string
name: string
networkId: string
projectId: 0
projectName: string
regionId: 0
regionName: string
type: string
Network 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 Network resource accepts the following input properties:
- Create
Router bool - Create external router to the network, default true
- Last
Updated string - The timestamp of the last update (use with update context).
- Metadata
Map Dictionary<string, string> - A map containing metadata, for example tags.
- Name string
- The name of the network.
- Network
Id string - The ID of this resource.
- Project
Id double - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- Project
Name string - The name of the project. Either 'projectid' or 'projectname' must be specified.
- Region
Id double - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- Region
Name string - The name of the region. Either 'regionid' or 'regionname' must be specified.
- Type string
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- Create
Router bool - Create external router to the network, default true
- Last
Updated string - The timestamp of the last update (use with update context).
- Metadata
Map map[string]string - A map containing metadata, for example tags.
- Name string
- The name of the network.
- Network
Id string - The ID of this resource.
- Project
Id float64 - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- Project
Name string - The name of the project. Either 'projectid' or 'projectname' must be specified.
- Region
Id float64 - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- Region
Name string - The name of the region. Either 'regionid' or 'regionname' must be specified.
- Type string
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- create
Router Boolean - Create external router to the network, default true
- last
Updated String - The timestamp of the last update (use with update context).
- metadata
Map Map<String,String> - A map containing metadata, for example tags.
- name String
- The name of the network.
- network
Id String - The ID of this resource.
- project
Id Double - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- project
Name String - The name of the project. Either 'projectid' or 'projectname' must be specified.
- region
Id Double - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- region
Name String - The name of the region. Either 'regionid' or 'regionname' must be specified.
- type String
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- create
Router boolean - Create external router to the network, default true
- last
Updated string - The timestamp of the last update (use with update context).
- metadata
Map {[key: string]: string} - A map containing metadata, for example tags.
- name string
- The name of the network.
- network
Id string - The ID of this resource.
- project
Id number - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- project
Name string - The name of the project. Either 'projectid' or 'projectname' must be specified.
- region
Id number - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- region
Name string - The name of the region. Either 'regionid' or 'regionname' must be specified.
- type string
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- create_
router bool - Create external router to the network, default true
- last_
updated str - The timestamp of the last update (use with update context).
- metadata_
map Mapping[str, str] - A map containing metadata, for example tags.
- name str
- The name of the network.
- network_
id str - The ID of this resource.
- project_
id float - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- project_
name str - The name of the project. Either 'projectid' or 'projectname' must be specified.
- region_
id float - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- region_
name str - The name of the region. Either 'regionid' or 'regionname' must be specified.
- type str
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- create
Router Boolean - Create external router to the network, default true
- last
Updated String - The timestamp of the last update (use with update context).
- metadata
Map Map<String> - A map containing metadata, for example tags.
- name String
- The name of the network.
- network
Id String - The ID of this resource.
- project
Id Number - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- project
Name String - The name of the project. Either 'projectid' or 'projectname' must be specified.
- region
Id Number - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- region
Name String - The name of the region. Either 'regionid' or 'regionname' must be specified.
- type String
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
Outputs
All input properties are implicitly available as output properties. Additionally, the Network resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Metadata
Read List<NetworkOnlies Metadata Read Only> - A list of read-only metadata items, e.g. tags.
- Mtu double
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- Id string
- The provider-assigned unique ID for this managed resource.
- Metadata
Read []NetworkOnlies Metadata Read Only - A list of read-only metadata items, e.g. tags.
- Mtu float64
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- id String
- The provider-assigned unique ID for this managed resource.
- metadata
Read List<NetworkOnlies Metadata Read Only> - A list of read-only metadata items, e.g. tags.
- mtu Double
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- id string
- The provider-assigned unique ID for this managed resource.
- metadata
Read NetworkOnlies Metadata Read Only[] - A list of read-only metadata items, e.g. tags.
- mtu number
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- id str
- The provider-assigned unique ID for this managed resource.
- metadata_
read_ Sequence[Networkonlies Metadata Read Only] - A list of read-only metadata items, e.g. tags.
- mtu float
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- id String
- The provider-assigned unique ID for this managed resource.
- metadata
Read List<Property Map>Onlies - A list of read-only metadata items, e.g. tags.
- mtu Number
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
Look up Existing Network Resource
Get an existing Network 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?: NetworkState, opts?: CustomResourceOptions): Network
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
create_router: Optional[bool] = None,
last_updated: Optional[str] = None,
metadata_map: Optional[Mapping[str, str]] = None,
metadata_read_onlies: Optional[Sequence[NetworkMetadataReadOnlyArgs]] = None,
mtu: Optional[float] = None,
name: Optional[str] = None,
network_id: Optional[str] = None,
project_id: Optional[float] = None,
project_name: Optional[str] = None,
region_id: Optional[float] = None,
region_name: Optional[str] = None,
type: Optional[str] = None) -> Network
func GetNetwork(ctx *Context, name string, id IDInput, state *NetworkState, opts ...ResourceOption) (*Network, error)
public static Network Get(string name, Input<string> id, NetworkState? state, CustomResourceOptions? opts = null)
public static Network get(String name, Output<String> id, NetworkState state, CustomResourceOptions options)
resources: _: type: edgecenter:Network 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.
- Create
Router bool - Create external router to the network, default true
- Last
Updated string - The timestamp of the last update (use with update context).
- Metadata
Map Dictionary<string, string> - A map containing metadata, for example tags.
- Metadata
Read List<NetworkOnlies Metadata Read Only> - A list of read-only metadata items, e.g. tags.
- Mtu double
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- Name string
- The name of the network.
- Network
Id string - The ID of this resource.
- Project
Id double - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- Project
Name string - The name of the project. Either 'projectid' or 'projectname' must be specified.
- Region
Id double - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- Region
Name string - The name of the region. Either 'regionid' or 'regionname' must be specified.
- Type string
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- Create
Router bool - Create external router to the network, default true
- Last
Updated string - The timestamp of the last update (use with update context).
- Metadata
Map map[string]string - A map containing metadata, for example tags.
- Metadata
Read []NetworkOnlies Metadata Read Only Args - A list of read-only metadata items, e.g. tags.
- Mtu float64
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- Name string
- The name of the network.
- Network
Id string - The ID of this resource.
- Project
Id float64 - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- Project
Name string - The name of the project. Either 'projectid' or 'projectname' must be specified.
- Region
Id float64 - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- Region
Name string - The name of the region. Either 'regionid' or 'regionname' must be specified.
- Type string
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- create
Router Boolean - Create external router to the network, default true
- last
Updated String - The timestamp of the last update (use with update context).
- metadata
Map Map<String,String> - A map containing metadata, for example tags.
- metadata
Read List<NetworkOnlies Metadata Read Only> - A list of read-only metadata items, e.g. tags.
- mtu Double
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- name String
- The name of the network.
- network
Id String - The ID of this resource.
- project
Id Double - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- project
Name String - The name of the project. Either 'projectid' or 'projectname' must be specified.
- region
Id Double - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- region
Name String - The name of the region. Either 'regionid' or 'regionname' must be specified.
- type String
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- create
Router boolean - Create external router to the network, default true
- last
Updated string - The timestamp of the last update (use with update context).
- metadata
Map {[key: string]: string} - A map containing metadata, for example tags.
- metadata
Read NetworkOnlies Metadata Read Only[] - A list of read-only metadata items, e.g. tags.
- mtu number
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- name string
- The name of the network.
- network
Id string - The ID of this resource.
- project
Id number - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- project
Name string - The name of the project. Either 'projectid' or 'projectname' must be specified.
- region
Id number - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- region
Name string - The name of the region. Either 'regionid' or 'regionname' must be specified.
- type string
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- create_
router bool - Create external router to the network, default true
- last_
updated str - The timestamp of the last update (use with update context).
- metadata_
map Mapping[str, str] - A map containing metadata, for example tags.
- metadata_
read_ Sequence[Networkonlies Metadata Read Only Args] - A list of read-only metadata items, e.g. tags.
- mtu float
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- name str
- The name of the network.
- network_
id str - The ID of this resource.
- project_
id float - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- project_
name str - The name of the project. Either 'projectid' or 'projectname' must be specified.
- region_
id float - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- region_
name str - The name of the region. Either 'regionid' or 'regionname' must be specified.
- type str
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
- create
Router Boolean - Create external router to the network, default true
- last
Updated String - The timestamp of the last update (use with update context).
- metadata
Map Map<String> - A map containing metadata, for example tags.
- metadata
Read List<Property Map>Onlies - A list of read-only metadata items, e.g. tags.
- mtu Number
- Maximum Transmission Unit (MTU) for the network. It determines the maximum packet size that can be transmitted without fragmentation.
- name String
- The name of the network.
- network
Id String - The ID of this resource.
- project
Id Number - The uuid of the project. Either 'projectid' or 'projectname' must be specified.
- project
Name String - The name of the project. Either 'projectid' or 'projectname' must be specified.
- region
Id Number - The uuid of the region. Either 'regionid' or 'regionname' must be specified.
- region
Name String - The name of the region. Either 'regionid' or 'regionname' must be specified.
- type String
- 'vlan' or 'vxlan' network type is allowed. Default value is 'vxlan'
Supporting Types
NetworkMetadataReadOnly, NetworkMetadataReadOnlyArgs
Import
import using <project_id>:<region_id>:<network_id> format
$ pulumi import edgecenter:index/network:Network metwork1 1:6:447d2959-8ae0-4ca0-8d47-9f050a3637d7
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- edgecenter edge-center/terraform-provider-edgecenter
- License
- Notes
- This Pulumi package is based on the
edgecenter
Terraform Provider.