opentelekomcloud.NatDnatRuleV2
Explore with Pulumi AI
Up-to-date reference of API arguments for NAT DNAT you can get at documentation portal
Manages a V2 DNAT rule resource within OpenTelekomCloud.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as opentelekomcloud from "@pulumi/opentelekomcloud";
const config = new pulumi.Config();
const natGwId = config.requireObject("natGwId");
const floatingIpId = config.requireObject("floatingIpId");
const privateIp = config.requireObject("privateIp");
const dnat1 = new opentelekomcloud.NatDnatRuleV2("dnat1", {
floatingIpId: floatingIpId,
natGatewayId: natGwId,
privateIp: _var.private_id,
internalServicePort: 993,
protocol: "tcp",
externalServicePort: 242,
});
import pulumi
import pulumi_opentelekomcloud as opentelekomcloud
config = pulumi.Config()
nat_gw_id = config.require_object("natGwId")
floating_ip_id = config.require_object("floatingIpId")
private_ip = config.require_object("privateIp")
dnat1 = opentelekomcloud.NatDnatRuleV2("dnat1",
floating_ip_id=floating_ip_id,
nat_gateway_id=nat_gw_id,
private_ip=var["private_id"],
internal_service_port=993,
protocol="tcp",
external_service_port=242)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/opentelekomcloud/opentelekomcloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
natGwId := cfg.RequireObject("natGwId")
floatingIpId := cfg.RequireObject("floatingIpId")
privateIp := cfg.RequireObject("privateIp")
_, err := opentelekomcloud.NewNatDnatRuleV2(ctx, "dnat1", &opentelekomcloud.NatDnatRuleV2Args{
FloatingIpId: pulumi.Any(floatingIpId),
NatGatewayId: pulumi.Any(natGwId),
PrivateIp: pulumi.Any(_var.Private_id),
InternalServicePort: pulumi.Float64(993),
Protocol: pulumi.String("tcp"),
ExternalServicePort: pulumi.Float64(242),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Opentelekomcloud = Pulumi.Opentelekomcloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var natGwId = config.RequireObject<dynamic>("natGwId");
var floatingIpId = config.RequireObject<dynamic>("floatingIpId");
var privateIp = config.RequireObject<dynamic>("privateIp");
var dnat1 = new Opentelekomcloud.NatDnatRuleV2("dnat1", new()
{
FloatingIpId = floatingIpId,
NatGatewayId = natGwId,
PrivateIp = @var.Private_id,
InternalServicePort = 993,
Protocol = "tcp",
ExternalServicePort = 242,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.opentelekomcloud.NatDnatRuleV2;
import com.pulumi.opentelekomcloud.NatDnatRuleV2Args;
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) {
final var config = ctx.config();
final var natGwId = config.get("natGwId");
final var floatingIpId = config.get("floatingIpId");
final var privateIp = config.get("privateIp");
var dnat1 = new NatDnatRuleV2("dnat1", NatDnatRuleV2Args.builder()
.floatingIpId(floatingIpId)
.natGatewayId(natGwId)
.privateIp(var_.private_id())
.internalServicePort(993)
.protocol("tcp")
.externalServicePort(242)
.build());
}
}
configuration:
natGwId:
type: dynamic
floatingIpId:
type: dynamic
privateIp:
type: dynamic
resources:
dnat1:
type: opentelekomcloud:NatDnatRuleV2
properties:
floatingIpId: ${floatingIpId}
natGatewayId: ${natGwId}
privateIp: ${var.private_id}
internalServicePort: 993
protocol: tcp
externalServicePort: 242
Create NatDnatRuleV2 Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new NatDnatRuleV2(name: string, args: NatDnatRuleV2Args, opts?: CustomResourceOptions);
@overload
def NatDnatRuleV2(resource_name: str,
args: NatDnatRuleV2Args,
opts: Optional[ResourceOptions] = None)
@overload
def NatDnatRuleV2(resource_name: str,
opts: Optional[ResourceOptions] = None,
external_service_port: Optional[float] = None,
floating_ip_id: Optional[str] = None,
internal_service_port: Optional[float] = None,
nat_gateway_id: Optional[str] = None,
protocol: Optional[str] = None,
nat_dnat_rule_v2_id: Optional[str] = None,
port_id: Optional[str] = None,
private_ip: Optional[str] = None,
timeouts: Optional[NatDnatRuleV2TimeoutsArgs] = None)
func NewNatDnatRuleV2(ctx *Context, name string, args NatDnatRuleV2Args, opts ...ResourceOption) (*NatDnatRuleV2, error)
public NatDnatRuleV2(string name, NatDnatRuleV2Args args, CustomResourceOptions? opts = null)
public NatDnatRuleV2(String name, NatDnatRuleV2Args args)
public NatDnatRuleV2(String name, NatDnatRuleV2Args args, CustomResourceOptions options)
type: opentelekomcloud:NatDnatRuleV2
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 NatDnatRuleV2Args
- 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 NatDnatRuleV2Args
- 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 NatDnatRuleV2Args
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args NatDnatRuleV2Args
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args NatDnatRuleV2Args
- 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 natDnatRuleV2Resource = new Opentelekomcloud.NatDnatRuleV2("natDnatRuleV2Resource", new()
{
ExternalServicePort = 0,
FloatingIpId = "string",
InternalServicePort = 0,
NatGatewayId = "string",
Protocol = "string",
NatDnatRuleV2Id = "string",
PortId = "string",
PrivateIp = "string",
Timeouts = new Opentelekomcloud.Inputs.NatDnatRuleV2TimeoutsArgs
{
Create = "string",
Delete = "string",
},
});
example, err := opentelekomcloud.NewNatDnatRuleV2(ctx, "natDnatRuleV2Resource", &opentelekomcloud.NatDnatRuleV2Args{
ExternalServicePort: pulumi.Float64(0),
FloatingIpId: pulumi.String("string"),
InternalServicePort: pulumi.Float64(0),
NatGatewayId: pulumi.String("string"),
Protocol: pulumi.String("string"),
NatDnatRuleV2Id: pulumi.String("string"),
PortId: pulumi.String("string"),
PrivateIp: pulumi.String("string"),
Timeouts: &opentelekomcloud.NatDnatRuleV2TimeoutsArgs{
Create: pulumi.String("string"),
Delete: pulumi.String("string"),
},
})
var natDnatRuleV2Resource = new NatDnatRuleV2("natDnatRuleV2Resource", NatDnatRuleV2Args.builder()
.externalServicePort(0)
.floatingIpId("string")
.internalServicePort(0)
.natGatewayId("string")
.protocol("string")
.natDnatRuleV2Id("string")
.portId("string")
.privateIp("string")
.timeouts(NatDnatRuleV2TimeoutsArgs.builder()
.create("string")
.delete("string")
.build())
.build());
nat_dnat_rule_v2_resource = opentelekomcloud.NatDnatRuleV2("natDnatRuleV2Resource",
external_service_port=0,
floating_ip_id="string",
internal_service_port=0,
nat_gateway_id="string",
protocol="string",
nat_dnat_rule_v2_id="string",
port_id="string",
private_ip="string",
timeouts={
"create": "string",
"delete": "string",
})
const natDnatRuleV2Resource = new opentelekomcloud.NatDnatRuleV2("natDnatRuleV2Resource", {
externalServicePort: 0,
floatingIpId: "string",
internalServicePort: 0,
natGatewayId: "string",
protocol: "string",
natDnatRuleV2Id: "string",
portId: "string",
privateIp: "string",
timeouts: {
create: "string",
"delete": "string",
},
});
type: opentelekomcloud:NatDnatRuleV2
properties:
externalServicePort: 0
floatingIpId: string
internalServicePort: 0
natDnatRuleV2Id: string
natGatewayId: string
portId: string
privateIp: string
protocol: string
timeouts:
create: string
delete: string
NatDnatRuleV2 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 NatDnatRuleV2 resource accepts the following input properties:
- External
Service doublePort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- Floating
Ip stringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- Internal
Service doublePort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- Nat
Gateway stringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- Protocol string
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- Nat
Dnat stringRule V2Id - Port
Id string Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- Private
Ip string Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- Timeouts
Nat
Dnat Rule V2Timeouts
- External
Service float64Port - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- Floating
Ip stringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- Internal
Service float64Port - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- Nat
Gateway stringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- Protocol string
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- Nat
Dnat stringRule V2Id - Port
Id string Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- Private
Ip string Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- Timeouts
Nat
Dnat Rule V2Timeouts Args
- external
Service DoublePort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- floating
Ip StringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- internal
Service DoublePort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- nat
Gateway StringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- protocol String
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- nat
Dnat StringRule V2Id - port
Id String Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- private
Ip String Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- timeouts
Nat
Dnat Rule V2Timeouts
- external
Service numberPort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- floating
Ip stringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- internal
Service numberPort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- nat
Gateway stringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- protocol string
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- nat
Dnat stringRule V2Id - port
Id string Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- private
Ip string Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- timeouts
Nat
Dnat Rule V2Timeouts
- external_
service_ floatport - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- floating_
ip_ strid - Specifies the ID of the floating IP address. Changing this creates a new resource.
- internal_
service_ floatport - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- nat_
gateway_ strid ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- protocol str
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- nat_
dnat_ strrule_ v2_ id - port_
id str Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- private_
ip str Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- timeouts
Nat
Dnat Rule V2Timeouts Args
- external
Service NumberPort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- floating
Ip StringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- internal
Service NumberPort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- nat
Gateway StringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- protocol String
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- nat
Dnat StringRule V2Id - port
Id String Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- private
Ip String Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- timeouts Property Map
Outputs
All input properties are implicitly available as output properties. Additionally, the NatDnatRuleV2 resource produces the following output properties:
- Created
At string - DNAT rule creation time.
- Floating
Ip stringAddress - The actual floating IP address.
- Id string
- The provider-assigned unique ID for this managed resource.
- Status string
- DNAT rule status.
- Tenant
Id string
- Created
At string - DNAT rule creation time.
- Floating
Ip stringAddress - The actual floating IP address.
- Id string
- The provider-assigned unique ID for this managed resource.
- Status string
- DNAT rule status.
- Tenant
Id string
- created
At String - DNAT rule creation time.
- floating
Ip StringAddress - The actual floating IP address.
- id String
- The provider-assigned unique ID for this managed resource.
- status String
- DNAT rule status.
- tenant
Id String
- created
At string - DNAT rule creation time.
- floating
Ip stringAddress - The actual floating IP address.
- id string
- The provider-assigned unique ID for this managed resource.
- status string
- DNAT rule status.
- tenant
Id string
- created_
at str - DNAT rule creation time.
- floating_
ip_ straddress - The actual floating IP address.
- id str
- The provider-assigned unique ID for this managed resource.
- status str
- DNAT rule status.
- tenant_
id str
- created
At String - DNAT rule creation time.
- floating
Ip StringAddress - The actual floating IP address.
- id String
- The provider-assigned unique ID for this managed resource.
- status String
- DNAT rule status.
- tenant
Id String
Look up Existing NatDnatRuleV2 Resource
Get an existing NatDnatRuleV2 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?: NatDnatRuleV2State, opts?: CustomResourceOptions): NatDnatRuleV2
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
created_at: Optional[str] = None,
external_service_port: Optional[float] = None,
floating_ip_address: Optional[str] = None,
floating_ip_id: Optional[str] = None,
internal_service_port: Optional[float] = None,
nat_dnat_rule_v2_id: Optional[str] = None,
nat_gateway_id: Optional[str] = None,
port_id: Optional[str] = None,
private_ip: Optional[str] = None,
protocol: Optional[str] = None,
status: Optional[str] = None,
tenant_id: Optional[str] = None,
timeouts: Optional[NatDnatRuleV2TimeoutsArgs] = None) -> NatDnatRuleV2
func GetNatDnatRuleV2(ctx *Context, name string, id IDInput, state *NatDnatRuleV2State, opts ...ResourceOption) (*NatDnatRuleV2, error)
public static NatDnatRuleV2 Get(string name, Input<string> id, NatDnatRuleV2State? state, CustomResourceOptions? opts = null)
public static NatDnatRuleV2 get(String name, Output<String> id, NatDnatRuleV2State state, CustomResourceOptions options)
resources: _: type: opentelekomcloud:NatDnatRuleV2 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.
- Created
At string - DNAT rule creation time.
- External
Service doublePort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- Floating
Ip stringAddress - The actual floating IP address.
- Floating
Ip stringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- Internal
Service doublePort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- Nat
Dnat stringRule V2Id - Nat
Gateway stringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- Port
Id string Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- Private
Ip string Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- Protocol string
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- Status string
- DNAT rule status.
- Tenant
Id string - Timeouts
Nat
Dnat Rule V2Timeouts
- Created
At string - DNAT rule creation time.
- External
Service float64Port - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- Floating
Ip stringAddress - The actual floating IP address.
- Floating
Ip stringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- Internal
Service float64Port - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- Nat
Dnat stringRule V2Id - Nat
Gateway stringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- Port
Id string Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- Private
Ip string Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- Protocol string
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- Status string
- DNAT rule status.
- Tenant
Id string - Timeouts
Nat
Dnat Rule V2Timeouts Args
- created
At String - DNAT rule creation time.
- external
Service DoublePort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- floating
Ip StringAddress - The actual floating IP address.
- floating
Ip StringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- internal
Service DoublePort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- nat
Dnat StringRule V2Id - nat
Gateway StringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- port
Id String Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- private
Ip String Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- protocol String
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- status String
- DNAT rule status.
- tenant
Id String - timeouts
Nat
Dnat Rule V2Timeouts
- created
At string - DNAT rule creation time.
- external
Service numberPort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- floating
Ip stringAddress - The actual floating IP address.
- floating
Ip stringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- internal
Service numberPort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- nat
Dnat stringRule V2Id - nat
Gateway stringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- port
Id string Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- private
Ip string Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- protocol string
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- status string
- DNAT rule status.
- tenant
Id string - timeouts
Nat
Dnat Rule V2Timeouts
- created_
at str - DNAT rule creation time.
- external_
service_ floatport - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- floating_
ip_ straddress - The actual floating IP address.
- floating_
ip_ strid - Specifies the ID of the floating IP address. Changing this creates a new resource.
- internal_
service_ floatport - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- nat_
dnat_ strrule_ v2_ id - nat_
gateway_ strid ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- port_
id str Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- private_
ip str Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- protocol str
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- status str
- DNAT rule status.
- tenant_
id str - timeouts
Nat
Dnat Rule V2Timeouts Args
- created
At String - DNAT rule creation time.
- external
Service NumberPort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new DNAT rule.
- floating
Ip StringAddress - The actual floating IP address.
- floating
Ip StringId - Specifies the ID of the floating IP address. Changing this creates a new resource.
- internal
Service NumberPort - Specifies port used by ECSs or BMSs to provide services for external systems. Changing this creates a new resource.
- nat
Dnat StringRule V2Id - nat
Gateway StringId ID of the NAT gateway this DNAT rule belongs to. Changing this creates a new DNAT rule.
You can create a DNAT rule only when status of the NAT gateway is set to
ACTIVE
andadmin_state_up
of the NAT gateway administrator toTrue
.- port
Id String Specifies the port ID of an ECS or a BMS. This parameter and
private_ip
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the VPC scenario, use
port_id
parameter.- private
Ip String Specifies the private IP address of a user, for example, the IP address of a VPC for dedicated connection. This parameter and
port_id
are alternative. Changing this creates a new DNAT rule.-> When the DNAT rule is used in the Direct Connect scenario, use
private_ip
parameter.- protocol String
Specifies the protocol type. Currently,
tcp
,udp
, andany
are supported. Changing this creates a new DNAT rule.If you create a rule that applies to all port types, set
internal_service_port
to0
,external_service_port
to0
, andprotocol
toany
.- status String
- DNAT rule status.
- tenant
Id String - timeouts Property Map
Supporting Types
NatDnatRuleV2Timeouts, NatDnatRuleV2TimeoutsArgs
Import
DNAT can be imported using the following format:
$ pulumi import opentelekomcloud:index/natDnatRuleV2:NatDnatRuleV2 dnat_1 f4f783a7-b908-4215-b018-724960e5df4a
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- opentelekomcloud opentelekomcloud/terraform-provider-opentelekomcloud
- License
- Notes
- This Pulumi package is based on the
opentelekomcloud
Terraform Provider.