Skip to content

Commit

Permalink
docs(nat): fix docs issues (#1024)
Browse files Browse the repository at this point in the history
  • Loading branch information
Zippo-Wang authored Sep 28, 2023
1 parent df72eaf commit 3421f92
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 30 deletions.
7 changes: 7 additions & 0 deletions docs/data-sources/nat_gateway_v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ data "flexibleengine_nat_gateway_v2" "natgateway" {

## Argument Reference

* `region` - (Optional, String) The region in which to query the data source. If omitted, the provider-level region
will be used.

* `id` - (Optional, String) Specifies the ID of the NAT gateway.

* `name` - (Optional, String) Specifies the NAT gateway name. The name can contain only digits, letters,
Expand All @@ -36,3 +39,7 @@ data "flexibleengine_nat_gateway_v2" "natgateway" {
characters, and angle brackets (<) and (>) are not allowed.

* `status` - (Optional, String) Specifies the status of the NAT gateway.

## Attribute Reference

All the arguments above can also be exported attributes.
18 changes: 9 additions & 9 deletions docs/resources/nat_dnat_rule_v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,33 +44,33 @@ resource "flexibleengine_nat_dnat_rule_v2" "dnat_2" {

The following arguments are supported:

* `nat_gateway_id` - (Required) Specifies the ID of the nat gateway this dnat rule belongs to.
* `nat_gateway_id` - (Required, String, ForceNew) Specifies the ID of the nat gateway this dnat rule belongs to.
Changing this creates a new dnat rule.

* `floating_ip_id` - (Required) Specifies the ID of the floating IP address.
* `floating_ip_id` - (Required, String, ForceNew) Specifies the ID of the floating IP address.
Changing this creates a new dnat rule.

* `protocol` - (Required) Specifies the protocol type. Currently,
* `protocol` - (Required, String, ForceNew) Specifies the protocol type. Currently,
TCP, UDP, and ANY are supported. Changing this creates a new dnat rule.

* `internal_service_port` - (Required) Specifies the port used by ECSs or BMSs to provide services
* `internal_service_port` - (Required, Int, ForceNew) Specifies the port used by ECSs or BMSs to provide services
that are accessible from external systems. Changing this creates a new dnat rule.

* `external_service_port` - (Required) Specifies the port for providing services
* `external_service_port` - (Required, Int, ForceNew) Specifies the port for providing services
that are accessible from external systems. Changing this creates a new dnat rule.

* `port_id` - (Optional) Specifies the port ID of an ECS or a BMS. This parameter is
* `port_id` - (Optional, String, ForceNew) Specifies the port ID of an ECS or a BMS. This parameter is
mandatory in VPC scenario. Changing this creates a new dnat rule.

* `private_ip` - (Optional) Specifies the private IP address of a user, for example,
* `private_ip` - (Optional, String, ForceNew) Specifies the private IP address of a user, for example,
the IP address of a VPC for dedicated connection. This parameter is mandatory in
Direct Connect scenario. Changing this creates a new dnat rule.

* `description` - (Optional) Specifies the description of the dnat rule.
* `description` - (Optional, String, ForceNew) Specifies the description of the dnat rule.
The value is a string of no more than 255 characters, and angle brackets (<>) are not allowed.
Changing this creates a new dnat rule.

## Attributes Reference
## Attribute Reference

In addition to the arguments listed above, the following computed attributes are exported:

Expand Down
6 changes: 3 additions & 3 deletions docs/resources/nat_gateway_v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ The following arguments are supported:
* `description` - (Optional, String) Specifies the description of the nat gateway.
The value contains 0 to 255 characters, and angle brackets (<) and (>) are not allowed.

## Attributes Reference
## Attribute Reference

In addition to all arguments above, the following attributes are exported:

Expand All @@ -69,8 +69,8 @@ In addition to all arguments above, the following attributes are exported:

This resource provides the following timeouts configuration options:

* `create` - Default is 10 minute.
* `delete` - Default is 10 minute.
* `create` - Default is 10 minutes.
* `delete` - Default is 10 minutes.

## Import

Expand Down
36 changes: 18 additions & 18 deletions docs/resources/nat_snat_rule_v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,41 +35,41 @@ resource "flexibleengine_nat_snat_rule_v2" "snat_2" {

The following arguments are supported:

* `region` - (Optional) The region in which to obtain the V2 nat client.
If omitted, the `region` argument of the provider is used. Changing this
creates a new snat rule.
* `region` - (Optional, String, ForceNew) The region in which to obtain the V2 nat client.
If omitted, the `region` argument of the provider is used. Changing this creates a new snat rule.

* `nat_gateway_id` - (Required) ID of the nat gateway this snat rule belongs to.
Changing this creates a new snat rule.
* `nat_gateway_id` - (Required, String, ForceNew) ID of the nat gateway this snat rule belongs to.
Changing this creates a new snat rule.

* `floating_ip_id` - (Required) ID of the floating ip this snat rule connets to.
Changing this creates a new snat rule.
* `floating_ip_id` - (Required, String, ForceNew) ID of the floating ip this snat rule connets to.
Changing this creates a new snat rule.

* `subnet_id` - (Optional) ID of the VPC Subnet this snat rule connects to.
This parameter and `cidr` are alternative. Changing this creates a new snat rule.
* `subnet_id` - (Optional, String, ForceNew) ID of the VPC Subnet this snat rule connects to.
This parameter and `cidr` are alternative. Changing this creates a new snat rule.

* `cidr` - (Optional) Specifies CIDR, which can be in the format of a network segment or a host IP address.
This parameter and `subnet_id` are alternative. Changing this creates a new snat rule.
* `cidr` - (Optional, String, ForceNew) Specifies CIDR, which can be in the format of a network segment or a host IP
address. This parameter and `subnet_id` are alternative. Changing this creates a new snat rule.

* `source_type` - (Optional) Specifies the scenario. The valid value is 0 (VPC scenario) and 1 (Direct Connect scenario).
Only `cidr` can be specified over a Direct Connect connection.
If no value is entered, the default value 0 (VPC scenario) is used.
Changing this creates a new snat rule.
* `source_type` - (Optional, Int, ForceNew) Specifies the scenario. The valid value is 0 (VPC scenario) and 1
(Direct Connect scenario). Only `cidr` can be specified over a Direct Connect connection.
If no value is entered, the default value 0 (VPC scenario) is used. Changing this creates a new snat rule.

## Attributes Reference
## Attribute Reference

In addition to all arguments above, the following attributes are exported:

* `id` - The resource ID in UUID format.

* `floating_ip_address` - The actual floating IP address.

* `status` - The status of the snat rule.

## Timeouts

This resource provides the following timeouts configuration options:

* `create` - Default is 10 minute.
* `delete` - Default is 10 minute.
* `create` - Default is 10 minutes.
* `delete` - Default is 10 minutes.

## Import

Expand Down

0 comments on commit 3421f92

Please sign in to comment.