UNPKG

@volcengine/pulumi

Version:

A Pulumi package for creating and managing volcengine cloud resources.

263 lines (262 loc) 8.04 kB
import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Provides a resource to manage apig gateway * ## 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 foo1 = new volcengine.vpc.Subnet("foo1", { * subnetName: "acc-test-subnet", * cidrBlock: "172.16.0.0/24", * zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id), * vpcId: fooVpc.id, * }); * const foo2 = new volcengine.vpc.Subnet("foo2", { * subnetName: "acc-test-subnet", * cidrBlock: "172.16.1.0/24", * zoneId: fooZones.then(fooZones => fooZones.zones?.[1]?.id), * vpcId: fooVpc.id, * }); * const fooApigGateway = new volcengine.apig.ApigGateway("fooApigGateway", { * type: "standard", * comments: "acc-test", * projectName: "default", * tags: [{ * key: "k1", * value: "v1", * }], * networkSpec: { * vpcId: fooVpc.id, * subnetIds: [ * foo1.id, * foo2.id, * ], * }, * resourceSpec: { * replicas: 2, * instanceSpecCode: "1c2g", * clbSpecCode: "small_1", * publicNetworkBillingType: "bandwidth", * publicNetworkBandwidth: 1, * networkType: { * enablePublicNetwork: true, * enablePrivateNetwork: true, * }, * }, * logSpec: { * enable: true, * projectId: "d3cb87c0-faeb-4074-b1ee-9bd747865a76", * topicId: "d339482e-d86d-4bd8-a9bb-f270417f00a1", * }, * monitorSpec: { * enable: true, * workspaceId: "4ed1caf3-279d-4c5f-8301-87ea38e92ffc", * }, * }); * ``` * * ## Import * * ApigGateway can be imported using the id, e.g. * * ```sh * $ pulumi import volcengine:apig/apigGateway:ApigGateway default resource_id * ``` */ export declare class ApigGateway extends pulumi.CustomResource { /** * Get an existing ApigGateway resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ApigGatewayState, opts?: pulumi.CustomResourceOptions): ApigGateway; /** * Returns true if the given object is an instance of ApigGateway. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is ApigGateway; /** * The backend spec of the api gateway. */ readonly backendSpec: pulumi.Output<outputs.apig.ApigGatewayBackendSpec>; /** * The comments of the api gateway. */ readonly comments: pulumi.Output<string | undefined>; /** * The create time of the api gateway. */ readonly createTime: pulumi.Output<string>; /** * The log spec of the api gateway. */ readonly logSpec: pulumi.Output<outputs.apig.ApigGatewayLogSpec>; /** * The error message of the api gateway. */ readonly message: pulumi.Output<string>; /** * The monitor spec of the api gateway. */ readonly monitorSpec: pulumi.Output<outputs.apig.ApigGatewayMonitorSpec>; /** * The name of the api gateway. */ readonly name: pulumi.Output<string>; /** * The network spec of the api gateway. */ readonly networkSpec: pulumi.Output<outputs.apig.ApigGatewayNetworkSpec>; /** * The project name of the api gateway. */ readonly projectName: pulumi.Output<string>; /** * The resource spec of the api gateway. */ readonly resourceSpec: pulumi.Output<outputs.apig.ApigGatewayResourceSpec>; /** * The status of the api gateway. */ readonly status: pulumi.Output<string>; /** * Tags. */ readonly tags: pulumi.Output<outputs.apig.ApigGatewayTag[] | undefined>; /** * The type of the api gateway. Valid values: `standard`, `serverless`. */ readonly type: pulumi.Output<string>; /** * The version of the api gateway. */ readonly version: pulumi.Output<string>; /** * Create a ApigGateway resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: ApigGatewayArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering ApigGateway resources. */ export interface ApigGatewayState { /** * The backend spec of the api gateway. */ backendSpec?: pulumi.Input<inputs.apig.ApigGatewayBackendSpec>; /** * The comments of the api gateway. */ comments?: pulumi.Input<string>; /** * The create time of the api gateway. */ createTime?: pulumi.Input<string>; /** * The log spec of the api gateway. */ logSpec?: pulumi.Input<inputs.apig.ApigGatewayLogSpec>; /** * The error message of the api gateway. */ message?: pulumi.Input<string>; /** * The monitor spec of the api gateway. */ monitorSpec?: pulumi.Input<inputs.apig.ApigGatewayMonitorSpec>; /** * The name of the api gateway. */ name?: pulumi.Input<string>; /** * The network spec of the api gateway. */ networkSpec?: pulumi.Input<inputs.apig.ApigGatewayNetworkSpec>; /** * The project name of the api gateway. */ projectName?: pulumi.Input<string>; /** * The resource spec of the api gateway. */ resourceSpec?: pulumi.Input<inputs.apig.ApigGatewayResourceSpec>; /** * The status of the api gateway. */ status?: pulumi.Input<string>; /** * Tags. */ tags?: pulumi.Input<pulumi.Input<inputs.apig.ApigGatewayTag>[]>; /** * The type of the api gateway. Valid values: `standard`, `serverless`. */ type?: pulumi.Input<string>; /** * The version of the api gateway. */ version?: pulumi.Input<string>; } /** * The set of arguments for constructing a ApigGateway resource. */ export interface ApigGatewayArgs { /** * The backend spec of the api gateway. */ backendSpec?: pulumi.Input<inputs.apig.ApigGatewayBackendSpec>; /** * The comments of the api gateway. */ comments?: pulumi.Input<string>; /** * The log spec of the api gateway. */ logSpec?: pulumi.Input<inputs.apig.ApigGatewayLogSpec>; /** * The monitor spec of the api gateway. */ monitorSpec?: pulumi.Input<inputs.apig.ApigGatewayMonitorSpec>; /** * The name of the api gateway. */ name?: pulumi.Input<string>; /** * The network spec of the api gateway. */ networkSpec: pulumi.Input<inputs.apig.ApigGatewayNetworkSpec>; /** * The project name of the api gateway. */ projectName?: pulumi.Input<string>; /** * The resource spec of the api gateway. */ resourceSpec?: pulumi.Input<inputs.apig.ApigGatewayResourceSpec>; /** * Tags. */ tags?: pulumi.Input<pulumi.Input<inputs.apig.ApigGatewayTag>[]>; /** * The type of the api gateway. Valid values: `standard`, `serverless`. */ type?: pulumi.Input<string>; }