flexibleengine.NetworkingPortV2
Explore with Pulumi AI
Manages a V2 port resource within FlexibleEngine.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as flexibleengine from "@pulumi/flexibleengine";
const exampleVpc = new flexibleengine.VpcV1("exampleVpc", {cidr: "192.168.0.0/16"});
const exampleSubnet = new flexibleengine.VpcSubnetV1("exampleSubnet", {
cidr: "192.168.0.0/24",
gatewayIp: "192.168.0.1",
vpcId: exampleVpc.vpcV1Id,
});
const port1 = new flexibleengine.NetworkingPortV2("port1", {
networkId: exampleSubnet.vpcSubnetV1Id,
adminStateUp: true,
});
import pulumi
import pulumi_flexibleengine as flexibleengine
example_vpc = flexibleengine.VpcV1("exampleVpc", cidr="192.168.0.0/16")
example_subnet = flexibleengine.VpcSubnetV1("exampleSubnet",
cidr="192.168.0.0/24",
gateway_ip="192.168.0.1",
vpc_id=example_vpc.vpc_v1_id)
port1 = flexibleengine.NetworkingPortV2("port1",
network_id=example_subnet.vpc_subnet_v1_id,
admin_state_up=True)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/flexibleengine/flexibleengine"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleVpc, err := flexibleengine.NewVpcV1(ctx, "exampleVpc", &flexibleengine.VpcV1Args{
Cidr: pulumi.String("192.168.0.0/16"),
})
if err != nil {
return err
}
exampleSubnet, err := flexibleengine.NewVpcSubnetV1(ctx, "exampleSubnet", &flexibleengine.VpcSubnetV1Args{
Cidr: pulumi.String("192.168.0.0/24"),
GatewayIp: pulumi.String("192.168.0.1"),
VpcId: exampleVpc.VpcV1Id,
})
if err != nil {
return err
}
_, err = flexibleengine.NewNetworkingPortV2(ctx, "port1", &flexibleengine.NetworkingPortV2Args{
NetworkId: exampleSubnet.VpcSubnetV1Id,
AdminStateUp: pulumi.Bool(true),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Flexibleengine = Pulumi.Flexibleengine;
return await Deployment.RunAsync(() =>
{
var exampleVpc = new Flexibleengine.VpcV1("exampleVpc", new()
{
Cidr = "192.168.0.0/16",
});
var exampleSubnet = new Flexibleengine.VpcSubnetV1("exampleSubnet", new()
{
Cidr = "192.168.0.0/24",
GatewayIp = "192.168.0.1",
VpcId = exampleVpc.VpcV1Id,
});
var port1 = new Flexibleengine.NetworkingPortV2("port1", new()
{
NetworkId = exampleSubnet.VpcSubnetV1Id,
AdminStateUp = true,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.flexibleengine.VpcV1;
import com.pulumi.flexibleengine.VpcV1Args;
import com.pulumi.flexibleengine.VpcSubnetV1;
import com.pulumi.flexibleengine.VpcSubnetV1Args;
import com.pulumi.flexibleengine.NetworkingPortV2;
import com.pulumi.flexibleengine.NetworkingPortV2Args;
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 exampleVpc = new VpcV1("exampleVpc", VpcV1Args.builder()
.cidr("192.168.0.0/16")
.build());
var exampleSubnet = new VpcSubnetV1("exampleSubnet", VpcSubnetV1Args.builder()
.cidr("192.168.0.0/24")
.gatewayIp("192.168.0.1")
.vpcId(exampleVpc.vpcV1Id())
.build());
var port1 = new NetworkingPortV2("port1", NetworkingPortV2Args.builder()
.networkId(exampleSubnet.vpcSubnetV1Id())
.adminStateUp("true")
.build());
}
}
resources:
exampleVpc:
type: flexibleengine:VpcV1
properties:
cidr: 192.168.0.0/16
exampleSubnet:
type: flexibleengine:VpcSubnetV1
properties:
cidr: 192.168.0.0/24
gatewayIp: 192.168.0.1
vpcId: ${exampleVpc.vpcV1Id}
port1:
type: flexibleengine:NetworkingPortV2
properties:
networkId: ${exampleSubnet.vpcSubnetV1Id}
adminStateUp: 'true'
Port With allowed_address_pairs
import * as pulumi from "@pulumi/pulumi";
import * as flexibleengine from "@pulumi/flexibleengine";
const port1 = new flexibleengine.NetworkingPortV2("port1", {
networkId: flexibleengine_vpc_subnet_v1.example_subnet.id,
adminStateUp: true,
allowedAddressPairs: [{
ipAddress: "192.168.0.0/24",
}],
});
import pulumi
import pulumi_flexibleengine as flexibleengine
port1 = flexibleengine.NetworkingPortV2("port1",
network_id=flexibleengine_vpc_subnet_v1["example_subnet"]["id"],
admin_state_up=True,
allowed_address_pairs=[{
"ip_address": "192.168.0.0/24",
}])
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/flexibleengine/flexibleengine"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := flexibleengine.NewNetworkingPortV2(ctx, "port1", &flexibleengine.NetworkingPortV2Args{
NetworkId: pulumi.Any(flexibleengine_vpc_subnet_v1.Example_subnet.Id),
AdminStateUp: pulumi.Bool(true),
AllowedAddressPairs: flexibleengine.NetworkingPortV2AllowedAddressPairArray{
&flexibleengine.NetworkingPortV2AllowedAddressPairArgs{
IpAddress: pulumi.String("192.168.0.0/24"),
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Flexibleengine = Pulumi.Flexibleengine;
return await Deployment.RunAsync(() =>
{
var port1 = new Flexibleengine.NetworkingPortV2("port1", new()
{
NetworkId = flexibleengine_vpc_subnet_v1.Example_subnet.Id,
AdminStateUp = true,
AllowedAddressPairs = new[]
{
new Flexibleengine.Inputs.NetworkingPortV2AllowedAddressPairArgs
{
IpAddress = "192.168.0.0/24",
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.flexibleengine.NetworkingPortV2;
import com.pulumi.flexibleengine.NetworkingPortV2Args;
import com.pulumi.flexibleengine.inputs.NetworkingPortV2AllowedAddressPairArgs;
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 port1 = new NetworkingPortV2("port1", NetworkingPortV2Args.builder()
.networkId(flexibleengine_vpc_subnet_v1.example_subnet().id())
.adminStateUp("true")
.allowedAddressPairs(NetworkingPortV2AllowedAddressPairArgs.builder()
.ipAddress("192.168.0.0/24")
.build())
.build());
}
}
resources:
port1:
type: flexibleengine:NetworkingPortV2
properties:
networkId: ${flexibleengine_vpc_subnet_v1.example_subnet.id}
adminStateUp: 'true'
allowedAddressPairs:
- ipAddress: 192.168.0.0/24
Notes
Ports and Instances
There are some notes to consider when connecting Instances to networks using
Ports. Please see the flexibleengine.ComputeInstanceV2
documentation for further
documentation.
Create NetworkingPortV2 Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new NetworkingPortV2(name: string, args: NetworkingPortV2Args, opts?: CustomResourceOptions);
@overload
def NetworkingPortV2(resource_name: str,
args: NetworkingPortV2Args,
opts: Optional[ResourceOptions] = None)
@overload
def NetworkingPortV2(resource_name: str,
opts: Optional[ResourceOptions] = None,
network_id: Optional[str] = None,
name: Optional[str] = None,
device_id: Optional[str] = None,
device_owner: Optional[str] = None,
fixed_ips: Optional[Sequence[NetworkingPortV2FixedIpArgs]] = None,
mac_address: Optional[str] = None,
admin_state_up: Optional[bool] = None,
allowed_address_pairs: Optional[Sequence[NetworkingPortV2AllowedAddressPairArgs]] = None,
networking_port_v2_id: Optional[str] = None,
region: Optional[str] = None,
security_group_ids: Optional[Sequence[str]] = None,
tenant_id: Optional[str] = None,
timeouts: Optional[NetworkingPortV2TimeoutsArgs] = None,
value_specs: Optional[Mapping[str, str]] = None)
func NewNetworkingPortV2(ctx *Context, name string, args NetworkingPortV2Args, opts ...ResourceOption) (*NetworkingPortV2, error)
public NetworkingPortV2(string name, NetworkingPortV2Args args, CustomResourceOptions? opts = null)
public NetworkingPortV2(String name, NetworkingPortV2Args args)
public NetworkingPortV2(String name, NetworkingPortV2Args args, CustomResourceOptions options)
type: flexibleengine:NetworkingPortV2
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 NetworkingPortV2Args
- 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 NetworkingPortV2Args
- 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 NetworkingPortV2Args
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args NetworkingPortV2Args
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args NetworkingPortV2Args
- 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 networkingPortV2Resource = new Flexibleengine.NetworkingPortV2("networkingPortV2Resource", new()
{
NetworkId = "string",
Name = "string",
DeviceId = "string",
DeviceOwner = "string",
FixedIps = new[]
{
new Flexibleengine.Inputs.NetworkingPortV2FixedIpArgs
{
SubnetId = "string",
IpAddress = "string",
},
},
AdminStateUp = false,
AllowedAddressPairs = new[]
{
new Flexibleengine.Inputs.NetworkingPortV2AllowedAddressPairArgs
{
IpAddress = "string",
MacAddress = "string",
},
},
NetworkingPortV2Id = "string",
Region = "string",
SecurityGroupIds = new[]
{
"string",
},
TenantId = "string",
Timeouts = new Flexibleengine.Inputs.NetworkingPortV2TimeoutsArgs
{
Create = "string",
Delete = "string",
},
ValueSpecs =
{
{ "string", "string" },
},
});
example, err := flexibleengine.NewNetworkingPortV2(ctx, "networkingPortV2Resource", &flexibleengine.NetworkingPortV2Args{
NetworkId: pulumi.String("string"),
Name: pulumi.String("string"),
DeviceId: pulumi.String("string"),
DeviceOwner: pulumi.String("string"),
FixedIps: flexibleengine.NetworkingPortV2FixedIpArray{
&flexibleengine.NetworkingPortV2FixedIpArgs{
SubnetId: pulumi.String("string"),
IpAddress: pulumi.String("string"),
},
},
AdminStateUp: pulumi.Bool(false),
AllowedAddressPairs: flexibleengine.NetworkingPortV2AllowedAddressPairArray{
&flexibleengine.NetworkingPortV2AllowedAddressPairArgs{
IpAddress: pulumi.String("string"),
MacAddress: pulumi.String("string"),
},
},
NetworkingPortV2Id: pulumi.String("string"),
Region: pulumi.String("string"),
SecurityGroupIds: pulumi.StringArray{
pulumi.String("string"),
},
TenantId: pulumi.String("string"),
Timeouts: &flexibleengine.NetworkingPortV2TimeoutsArgs{
Create: pulumi.String("string"),
Delete: pulumi.String("string"),
},
ValueSpecs: pulumi.StringMap{
"string": pulumi.String("string"),
},
})
var networkingPortV2Resource = new NetworkingPortV2("networkingPortV2Resource", NetworkingPortV2Args.builder()
.networkId("string")
.name("string")
.deviceId("string")
.deviceOwner("string")
.fixedIps(NetworkingPortV2FixedIpArgs.builder()
.subnetId("string")
.ipAddress("string")
.build())
.adminStateUp(false)
.allowedAddressPairs(NetworkingPortV2AllowedAddressPairArgs.builder()
.ipAddress("string")
.macAddress("string")
.build())
.networkingPortV2Id("string")
.region("string")
.securityGroupIds("string")
.tenantId("string")
.timeouts(NetworkingPortV2TimeoutsArgs.builder()
.create("string")
.delete("string")
.build())
.valueSpecs(Map.of("string", "string"))
.build());
networking_port_v2_resource = flexibleengine.NetworkingPortV2("networkingPortV2Resource",
network_id="string",
name="string",
device_id="string",
device_owner="string",
fixed_ips=[{
"subnet_id": "string",
"ip_address": "string",
}],
admin_state_up=False,
allowed_address_pairs=[{
"ip_address": "string",
"mac_address": "string",
}],
networking_port_v2_id="string",
region="string",
security_group_ids=["string"],
tenant_id="string",
timeouts={
"create": "string",
"delete": "string",
},
value_specs={
"string": "string",
})
const networkingPortV2Resource = new flexibleengine.NetworkingPortV2("networkingPortV2Resource", {
networkId: "string",
name: "string",
deviceId: "string",
deviceOwner: "string",
fixedIps: [{
subnetId: "string",
ipAddress: "string",
}],
adminStateUp: false,
allowedAddressPairs: [{
ipAddress: "string",
macAddress: "string",
}],
networkingPortV2Id: "string",
region: "string",
securityGroupIds: ["string"],
tenantId: "string",
timeouts: {
create: "string",
"delete": "string",
},
valueSpecs: {
string: "string",
},
});
type: flexibleengine:NetworkingPortV2
properties:
adminStateUp: false
allowedAddressPairs:
- ipAddress: string
macAddress: string
deviceId: string
deviceOwner: string
fixedIps:
- ipAddress: string
subnetId: string
name: string
networkId: string
networkingPortV2Id: string
region: string
securityGroupIds:
- string
tenantId: string
timeouts:
create: string
delete: string
valueSpecs:
string: string
NetworkingPortV2 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 NetworkingPortV2 resource accepts the following input properties:
- Network
Id string - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- Admin
State boolUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - Allowed
Address List<NetworkingPairs Port V2Allowed Address Pair> - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- Device
Id string - The ID of the device attached to the port. Changing this creates a new port.
- Device
Owner string - The device owner of the Port. Changing this creates a new port.
- Fixed
Ips List<NetworkingPort V2Fixed Ip> - An array of desired IPs for this port. The object structure is described below.
- Mac
Address string - The additional MAC address.
- Name string
- A unique name for the port. Changing this
updates the
name
of an existing port. - Networking
Port stringV2Id - Region string
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - Security
Group List<string>Ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- Tenant
Id string - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- Timeouts
Networking
Port V2Timeouts - Value
Specs Dictionary<string, string> Map of additional options.
The
fixed_ip
block supports:
- Network
Id string - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- Admin
State boolUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - Allowed
Address []NetworkingPairs Port V2Allowed Address Pair Args - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- Device
Id string - The ID of the device attached to the port. Changing this creates a new port.
- Device
Owner string - The device owner of the Port. Changing this creates a new port.
- Fixed
Ips []NetworkingPort V2Fixed Ip Args - An array of desired IPs for this port. The object structure is described below.
- Mac
Address string - The additional MAC address.
- Name string
- A unique name for the port. Changing this
updates the
name
of an existing port. - Networking
Port stringV2Id - Region string
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - Security
Group []stringIds - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- Tenant
Id string - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- Timeouts
Networking
Port V2Timeouts Args - Value
Specs map[string]string Map of additional options.
The
fixed_ip
block supports:
- network
Id String - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- admin
State BooleanUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - allowed
Address List<NetworkingPairs Port V2Allowed Address Pair> - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- device
Id String - The ID of the device attached to the port. Changing this creates a new port.
- device
Owner String - The device owner of the Port. Changing this creates a new port.
- fixed
Ips List<NetworkingPort V2Fixed Ip> - An array of desired IPs for this port. The object structure is described below.
- mac
Address String - The additional MAC address.
- name String
- A unique name for the port. Changing this
updates the
name
of an existing port. - networking
Port StringV2Id - region String
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - security
Group List<String>Ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- tenant
Id String - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- timeouts
Networking
Port V2Timeouts - value
Specs Map<String,String> Map of additional options.
The
fixed_ip
block supports:
- network
Id string - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- admin
State booleanUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - allowed
Address NetworkingPairs Port V2Allowed Address Pair[] - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- device
Id string - The ID of the device attached to the port. Changing this creates a new port.
- device
Owner string - The device owner of the Port. Changing this creates a new port.
- fixed
Ips NetworkingPort V2Fixed Ip[] - An array of desired IPs for this port. The object structure is described below.
- mac
Address string - The additional MAC address.
- name string
- A unique name for the port. Changing this
updates the
name
of an existing port. - networking
Port stringV2Id - region string
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - security
Group string[]Ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- tenant
Id string - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- timeouts
Networking
Port V2Timeouts - value
Specs {[key: string]: string} Map of additional options.
The
fixed_ip
block supports:
- network_
id str - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- admin_
state_ boolup - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - allowed_
address_ Sequence[Networkingpairs Port V2Allowed Address Pair Args] - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- device_
id str - The ID of the device attached to the port. Changing this creates a new port.
- device_
owner str - The device owner of the Port. Changing this creates a new port.
- fixed_
ips Sequence[NetworkingPort V2Fixed Ip Args] - An array of desired IPs for this port. The object structure is described below.
- mac_
address str - The additional MAC address.
- name str
- A unique name for the port. Changing this
updates the
name
of an existing port. - networking_
port_ strv2_ id - region str
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - security_
group_ Sequence[str]ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- tenant_
id str - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- timeouts
Networking
Port V2Timeouts Args - value_
specs Mapping[str, str] Map of additional options.
The
fixed_ip
block supports:
- network
Id String - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- admin
State BooleanUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - allowed
Address List<Property Map>Pairs - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- device
Id String - The ID of the device attached to the port. Changing this creates a new port.
- device
Owner String - The device owner of the Port. Changing this creates a new port.
- fixed
Ips List<Property Map> - An array of desired IPs for this port. The object structure is described below.
- mac
Address String - The additional MAC address.
- name String
- A unique name for the port. Changing this
updates the
name
of an existing port. - networking
Port StringV2Id - region String
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - security
Group List<String>Ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- tenant
Id String - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- timeouts Property Map
- value
Specs Map<String> Map of additional options.
The
fixed_ip
block supports:
Outputs
All input properties are implicitly available as output properties. Additionally, the NetworkingPortV2 resource produces the following output properties:
- All
Fixed List<string>Ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- Id string
- The provider-assigned unique ID for this managed resource.
- All
Fixed []stringIps - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- Id string
- The provider-assigned unique ID for this managed resource.
- all
Fixed List<String>Ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- id String
- The provider-assigned unique ID for this managed resource.
- all
Fixed string[]Ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- id string
- The provider-assigned unique ID for this managed resource.
- all_
fixed_ Sequence[str]ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- id str
- The provider-assigned unique ID for this managed resource.
- all
Fixed List<String>Ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing NetworkingPortV2 Resource
Get an existing NetworkingPortV2 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?: NetworkingPortV2State, opts?: CustomResourceOptions): NetworkingPortV2
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
admin_state_up: Optional[bool] = None,
all_fixed_ips: Optional[Sequence[str]] = None,
allowed_address_pairs: Optional[Sequence[NetworkingPortV2AllowedAddressPairArgs]] = None,
device_id: Optional[str] = None,
device_owner: Optional[str] = None,
fixed_ips: Optional[Sequence[NetworkingPortV2FixedIpArgs]] = None,
mac_address: Optional[str] = None,
name: Optional[str] = None,
network_id: Optional[str] = None,
networking_port_v2_id: Optional[str] = None,
region: Optional[str] = None,
security_group_ids: Optional[Sequence[str]] = None,
tenant_id: Optional[str] = None,
timeouts: Optional[NetworkingPortV2TimeoutsArgs] = None,
value_specs: Optional[Mapping[str, str]] = None) -> NetworkingPortV2
func GetNetworkingPortV2(ctx *Context, name string, id IDInput, state *NetworkingPortV2State, opts ...ResourceOption) (*NetworkingPortV2, error)
public static NetworkingPortV2 Get(string name, Input<string> id, NetworkingPortV2State? state, CustomResourceOptions? opts = null)
public static NetworkingPortV2 get(String name, Output<String> id, NetworkingPortV2State state, CustomResourceOptions options)
resources: _: type: flexibleengine:NetworkingPortV2 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.
- Admin
State boolUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - All
Fixed List<string>Ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- Allowed
Address List<NetworkingPairs Port V2Allowed Address Pair> - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- Device
Id string - The ID of the device attached to the port. Changing this creates a new port.
- Device
Owner string - The device owner of the Port. Changing this creates a new port.
- Fixed
Ips List<NetworkingPort V2Fixed Ip> - An array of desired IPs for this port. The object structure is described below.
- Mac
Address string - The additional MAC address.
- Name string
- A unique name for the port. Changing this
updates the
name
of an existing port. - Network
Id string - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- Networking
Port stringV2Id - Region string
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - Security
Group List<string>Ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- Tenant
Id string - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- Timeouts
Networking
Port V2Timeouts - Value
Specs Dictionary<string, string> Map of additional options.
The
fixed_ip
block supports:
- Admin
State boolUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - All
Fixed []stringIps - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- Allowed
Address []NetworkingPairs Port V2Allowed Address Pair Args - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- Device
Id string - The ID of the device attached to the port. Changing this creates a new port.
- Device
Owner string - The device owner of the Port. Changing this creates a new port.
- Fixed
Ips []NetworkingPort V2Fixed Ip Args - An array of desired IPs for this port. The object structure is described below.
- Mac
Address string - The additional MAC address.
- Name string
- A unique name for the port. Changing this
updates the
name
of an existing port. - Network
Id string - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- Networking
Port stringV2Id - Region string
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - Security
Group []stringIds - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- Tenant
Id string - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- Timeouts
Networking
Port V2Timeouts Args - Value
Specs map[string]string Map of additional options.
The
fixed_ip
block supports:
- admin
State BooleanUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - all
Fixed List<String>Ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- allowed
Address List<NetworkingPairs Port V2Allowed Address Pair> - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- device
Id String - The ID of the device attached to the port. Changing this creates a new port.
- device
Owner String - The device owner of the Port. Changing this creates a new port.
- fixed
Ips List<NetworkingPort V2Fixed Ip> - An array of desired IPs for this port. The object structure is described below.
- mac
Address String - The additional MAC address.
- name String
- A unique name for the port. Changing this
updates the
name
of an existing port. - network
Id String - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- networking
Port StringV2Id - region String
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - security
Group List<String>Ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- tenant
Id String - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- timeouts
Networking
Port V2Timeouts - value
Specs Map<String,String> Map of additional options.
The
fixed_ip
block supports:
- admin
State booleanUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - all
Fixed string[]Ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- allowed
Address NetworkingPairs Port V2Allowed Address Pair[] - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- device
Id string - The ID of the device attached to the port. Changing this creates a new port.
- device
Owner string - The device owner of the Port. Changing this creates a new port.
- fixed
Ips NetworkingPort V2Fixed Ip[] - An array of desired IPs for this port. The object structure is described below.
- mac
Address string - The additional MAC address.
- name string
- A unique name for the port. Changing this
updates the
name
of an existing port. - network
Id string - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- networking
Port stringV2Id - region string
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - security
Group string[]Ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- tenant
Id string - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- timeouts
Networking
Port V2Timeouts - value
Specs {[key: string]: string} Map of additional options.
The
fixed_ip
block supports:
- admin_
state_ boolup - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - all_
fixed_ Sequence[str]ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- allowed_
address_ Sequence[Networkingpairs Port V2Allowed Address Pair Args] - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- device_
id str - The ID of the device attached to the port. Changing this creates a new port.
- device_
owner str - The device owner of the Port. Changing this creates a new port.
- fixed_
ips Sequence[NetworkingPort V2Fixed Ip Args] - An array of desired IPs for this port. The object structure is described below.
- mac_
address str - The additional MAC address.
- name str
- A unique name for the port. Changing this
updates the
name
of an existing port. - network_
id str - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- networking_
port_ strv2_ id - region str
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - security_
group_ Sequence[str]ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- tenant_
id str - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- timeouts
Networking
Port V2Timeouts Args - value_
specs Mapping[str, str] Map of additional options.
The
fixed_ip
block supports:
- admin
State BooleanUp - Administrative up/down status for the port
(must be "true" or "false" if provided). Changing this updates the
admin_state_up
of an existing port. - all
Fixed List<String>Ips - The collection of Fixed IP addresses on the port in the order returned by the Network v2 API.
- allowed
Address List<Property Map>Pairs - An array of IP/MAC Address pairs of additional IP addresses that can be active on this port. The object structure is described below.
- device
Id String - The ID of the device attached to the port. Changing this creates a new port.
- device
Owner String - The device owner of the Port. Changing this creates a new port.
- fixed
Ips List<Property Map> - An array of desired IPs for this port. The object structure is described below.
- mac
Address String - The additional MAC address.
- name String
- A unique name for the port. Changing this
updates the
name
of an existing port. - network
Id String - The ID of the VPC Subnet to attach the port to. Changing this creates a new port.
- networking
Port StringV2Id - region String
- The region in which to allocate the port. If omitted, the
region
argument of the provider is used. Changing this creates a new port. - security
Group List<String>Ids - A list of security group IDs to apply to the port. The security groups must be specified by ID and not name (as opposed to how they are configured with the Compute Instance).
- tenant
Id String - The owner of the Port. Required if admin wants to create a port for another tenant. Changing this creates a new port.
- timeouts Property Map
- value
Specs Map<String> Map of additional options.
The
fixed_ip
block supports:
Supporting Types
NetworkingPortV2AllowedAddressPair, NetworkingPortV2AllowedAddressPairArgs
- Ip
Address string - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- Mac
Address string - The additional MAC address.
- Ip
Address string - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- Mac
Address string - The additional MAC address.
- ip
Address String - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- mac
Address String - The additional MAC address.
- ip
Address string - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- mac
Address string - The additional MAC address.
- ip_
address str - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- mac_
address str - The additional MAC address.
- ip
Address String - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- mac
Address String - The additional MAC address.
NetworkingPortV2FixedIp, NetworkingPortV2FixedIpArgs
- Subnet
Id string - The
ipv4_subnet_id
oripv6_subnet_id
of the VPC Subnet in which to allocate IP address for this port. - Ip
Address string - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- Subnet
Id string - The
ipv4_subnet_id
oripv6_subnet_id
of the VPC Subnet in which to allocate IP address for this port. - Ip
Address string - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- subnet
Id String - The
ipv4_subnet_id
oripv6_subnet_id
of the VPC Subnet in which to allocate IP address for this port. - ip
Address String - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- subnet
Id string - The
ipv4_subnet_id
oripv6_subnet_id
of the VPC Subnet in which to allocate IP address for this port. - ip
Address string - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- subnet_
id str - The
ipv4_subnet_id
oripv6_subnet_id
of the VPC Subnet in which to allocate IP address for this port. - ip_
address str - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
- subnet
Id String - The
ipv4_subnet_id
oripv6_subnet_id
of the VPC Subnet in which to allocate IP address for this port. - ip
Address String - The additional IP address. The value can be an IP Address or a CIDR, and can not be 0.0.0.0. A server connected to the port can send a packet with source address which matches one of the specified allowed address pairs. It is recommended to configure an independent security group for the port if a large CIDR block (subnet mask less than 24) is configured.
NetworkingPortV2Timeouts, NetworkingPortV2TimeoutsArgs
Import
Ports can be imported using the id
, e.g.
$ pulumi import flexibleengine:index/networkingPortV2:NetworkingPortV2 port_1 eae26a3e-1c33-4cc1-9c31-0cd729c438a1
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- flexibleengine flexibleenginecloud/terraform-provider-flexibleengine
- License
- Notes
- This Pulumi package is based on the
flexibleengine
Terraform Provider.