@volcengine/pulumi
Version:
A Pulumi package for creating and managing volcengine cloud resources.
216 lines (215 loc) • 6.01 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
* Use this data source to query detailed information of nat gateways
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as volcengine from "@pulumi/volcengine";
* import * as volcengine from "@volcengine/pulumi";
*
* const fooZones = volcengine.ecs.getZones({});
* const fooVpc = new volcengine.vpc.Vpc("fooVpc", {
* vpcName: "acc-test-vpc",
* cidrBlock: "172.16.0.0/16",
* });
* const fooSubnet = new volcengine.vpc.Subnet("fooSubnet", {
* subnetName: "acc-test-subnet",
* cidrBlock: "172.16.0.0/24",
* zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
* vpcId: fooVpc.id,
* });
* const fooGateway: volcengine.nat.Gateway[] = [];
* for (const range = {value: 0}; range.value < 3; range.value++) {
* fooGateway.push(new volcengine.nat.Gateway(`fooGateway-${range.value}`, {
* vpcId: fooVpc.id,
* subnetId: fooSubnet.id,
* spec: "Small",
* natGatewayName: `acc-test-ng-${range.value}`,
* description: "acc-test",
* billingType: "PostPaid",
* projectName: "default",
* tags: [{
* key: "k1",
* value: "v1",
* }],
* }));
* }
* const fooGateways = volcengine.nat.getGatewaysOutput({
* ids: fooGateway.map(__item => __item.id),
* });
* ```
*/
/** @deprecated volcengine.nat.Gateways has been deprecated in favor of volcengine.nat.getGateways */
export declare function gateways(args?: GatewaysArgs, opts?: pulumi.InvokeOptions): Promise<GatewaysResult>;
/**
* A collection of arguments for invoking Gateways.
*/
export interface GatewaysArgs {
/**
* The description of the NatGateway.
*/
description?: string;
/**
* The list of NatGateway IDs.
*/
ids?: string[];
/**
* The Name Regex of NatGateway.
*/
nameRegex?: string;
/**
* The name of the NatGateway.
*/
natGatewayName?: string;
/**
* File name where to save data source results.
*/
outputFile?: string;
/**
* The specification of the NatGateway.
*/
spec?: string;
/**
* The id of the Subnet.
*/
subnetId?: string;
/**
* Tags.
*/
tags?: inputs.nat.GatewaysTag[];
/**
* The id of the VPC.
*/
vpcId?: string;
}
/**
* A collection of values returned by Gateways.
*/
export interface GatewaysResult {
/**
* The description of the NatGateway.
*/
readonly description?: string;
/**
* The provider-assigned unique ID for this managed resource.
*/
readonly id: string;
readonly ids?: string[];
readonly nameRegex?: string;
/**
* The name of the NatGateway.
*/
readonly natGatewayName?: string;
/**
* The collection of NatGateway query.
*/
readonly natGateways: outputs.nat.GatewaysNatGateway[];
readonly outputFile?: string;
/**
* The specification of the NatGateway.
*/
readonly spec?: string;
/**
* The ID of the Subnet.
*/
readonly subnetId?: string;
/**
* Tags.
*/
readonly tags?: outputs.nat.GatewaysTag[];
/**
* The total count of NatGateway query.
*/
readonly totalCount: number;
/**
* The ID of the VPC.
*/
readonly vpcId?: string;
}
/**
* Use this data source to query detailed information of nat gateways
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as volcengine from "@pulumi/volcengine";
* import * as volcengine from "@volcengine/pulumi";
*
* const fooZones = volcengine.ecs.getZones({});
* const fooVpc = new volcengine.vpc.Vpc("fooVpc", {
* vpcName: "acc-test-vpc",
* cidrBlock: "172.16.0.0/16",
* });
* const fooSubnet = new volcengine.vpc.Subnet("fooSubnet", {
* subnetName: "acc-test-subnet",
* cidrBlock: "172.16.0.0/24",
* zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
* vpcId: fooVpc.id,
* });
* const fooGateway: volcengine.nat.Gateway[] = [];
* for (const range = {value: 0}; range.value < 3; range.value++) {
* fooGateway.push(new volcengine.nat.Gateway(`fooGateway-${range.value}`, {
* vpcId: fooVpc.id,
* subnetId: fooSubnet.id,
* spec: "Small",
* natGatewayName: `acc-test-ng-${range.value}`,
* description: "acc-test",
* billingType: "PostPaid",
* projectName: "default",
* tags: [{
* key: "k1",
* value: "v1",
* }],
* }));
* }
* const fooGateways = volcengine.nat.getGatewaysOutput({
* ids: fooGateway.map(__item => __item.id),
* });
* ```
*/
/** @deprecated volcengine.nat.Gateways has been deprecated in favor of volcengine.nat.getGateways */
export declare function gatewaysOutput(args?: GatewaysOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output<GatewaysResult>;
/**
* A collection of arguments for invoking Gateways.
*/
export interface GatewaysOutputArgs {
/**
* The description of the NatGateway.
*/
description?: pulumi.Input<string>;
/**
* The list of NatGateway IDs.
*/
ids?: pulumi.Input<pulumi.Input<string>[]>;
/**
* The Name Regex of NatGateway.
*/
nameRegex?: pulumi.Input<string>;
/**
* The name of the NatGateway.
*/
natGatewayName?: pulumi.Input<string>;
/**
* File name where to save data source results.
*/
outputFile?: pulumi.Input<string>;
/**
* The specification of the NatGateway.
*/
spec?: pulumi.Input<string>;
/**
* The id of the Subnet.
*/
subnetId?: pulumi.Input<string>;
/**
* Tags.
*/
tags?: pulumi.Input<pulumi.Input<inputs.nat.GatewaysTagArgs>[]>;
/**
* The id of the VPC.
*/
vpcId?: pulumi.Input<string>;
}