DATASOURCE::VPC::NatIpCidrs

Updated at: 2024-12-26 09:27

DATASOURCE::VPC::NatIpCidrs is used to query the CIDR blocks of a NAT gateway.

Syntax

{
  "Type": "DATASOURCE::VPC::NatIpCidrs",
  "Properties": {
    "NatIpCidr": String,
    "NatGatewayId": String,
    "RefreshOptions": String
  }
}

Properties

Property

Type

Required

Editable

Description

Constraint

NatIpCidr

String

No

Yes

The CIDR block of the NAT gateway.

None.

NatGatewayId

String

Yes

Yes

The ID of the Virtual Private Cloud (VPC) NAT gateway.

None.

RefreshOptions

String

No

Yes

The refresh policy for data source resources when the stack is updated.

Valid values:

  • Never (default): does not refresh data source resources when the stack is updated.

  • Always: refreshes data source resources when the stack is updated.

Return values

Fn::GetAtt

  • NatIpCidrIds: the IDs of the CIDR blocks of the NAT gateway.

  • NatIpCidrs: details of the CIDR blocks of the NAT gateway.

Property

Type

Description

Constraint

NatIpCidrIds

List

The IDs of the CIDR blocks of the NAT gateway.

None.

NatIpCidrs

List

Details of the CIDR blocks of the NAT gateway.

None.

Status

String

The state of the CIDR block of the NAT gateway.

The value Available is returned for this property.

NatIpCidr

String

The CIDR block of the NAT gateway.

None.

NatGatewayId

String

The ID of the VPC NAT gateway.

None.

NatIpCidrId

String

The ID of the CIDR block of the NAT gateway.

None.

NatIpCidrDescription

String

The description of the CIDR block of the NAT gateway.

None.

CreateTime

String

The time when the CIDR block of the NAT gateway was created.

None.

IsDefault

Boolean

Indicates whether the CIDR block is the default CIDR block of the NAT gateway.

Valid values:

  • true

  • false

DryRun

Boolean

Indicates whether only a dry run is performed.

Valid values:

  • true: Only a dry run is performed. The CIDR blocks of the NAT gateway are not queried. The system checks your AccessKey pair, the permissions of RAM users, and the required parameters. If the request fails the dry run, an error code is returned. If the request passes the dry run, DryRunOperation is returned.

  • false: A dry run and the actual request are performed. If the request passes the dry run, an HTTP 2XX status code is returned and the CIDR blocks of the NAT gateway are queried.

Examples

YAML
JSON
ROSTemplateFormatVersion: '2015-09-01'
Parameters: {}
Resources:
  ExtensionDataSource:
    Type: DATASOURCE::VPC::NatIpCidrs
    Properties:
      NatIpCidr: 172.16.0.0/24
      NatGatewayId: ngw-gw8v16wgvtq26vh59****
Outputs:
  NatIpCidrIds:
    Description: The list of nat ip cidr IDs.
    Value:
      Fn::GetAtt:
        - ExtensionDataSource
        - NatIpCidrIds
  NatIpCidrs:
    Description: The list of nat ip cidrs.
    Value:
      Fn::GetAtt:
        - ExtensionDataSource
        - NatIpCidrs
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
  },
  "Resources": {
    "ExtensionDataSource": {
      "Type": "DATASOURCE::VPC::NatIpCidrs",
      "Properties": {
        "NatIpCidr": "172.16.0.0/24",
        "NatGatewayId": "ngw-gw8v16wgvtq26vh59****"
      }
    }
  },
  "Outputs": {
    "NatIpCidrIds": {
      "Description": "The list of nat ip cidr IDs.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionDataSource",
          "NatIpCidrIds"
        ]
      }
    },
    "NatIpCidrs": {
      "Description": "The list of nat ip cidrs.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionDataSource",
          "NatIpCidrs"
        ]
      }
    }
  }
}
  • On this page (1, T)
  • Syntax
  • Properties
  • Return values
  • Examples
Feedback
phone Contact Us

Chat now with Alibaba Cloud Customer Service to assist you in finding the right products and services to meet your needs.

alicare alicarealicarealicare