1. Packages
  2. Alibaba Cloud
  3. API Docs
  4. databasegateway
  5. Gateway
Alibaba Cloud v3.59.0 published on Friday, Jul 12, 2024 by Pulumi

alicloud.databasegateway.Gateway

Explore with Pulumi AI

alicloud logo
Alibaba Cloud v3.59.0 published on Friday, Jul 12, 2024 by Pulumi

    Provides a Database Gateway Gateway resource.

    For information about Database Gateway Gateway and how to use it, see What is Gateway.

    NOTE: Available in v1.135.0+.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const example = new alicloud.databasegateway.Gateway("example", {gatewayName: "example_value"});
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    example = alicloud.databasegateway.Gateway("example", gateway_name="example_value")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/databasegateway"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := databasegateway.NewGateway(ctx, "example", &databasegateway.GatewayArgs{
    			GatewayName: pulumi.String("example_value"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new AliCloud.DatabaseGateway.Gateway("example", new()
        {
            GatewayName = "example_value",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.databasegateway.Gateway;
    import com.pulumi.alicloud.databasegateway.GatewayArgs;
    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) {
            var example = new Gateway("example", GatewayArgs.builder()
                .gatewayName("example_value")
                .build());
    
        }
    }
    
    resources:
      example:
        type: alicloud:databasegateway:Gateway
        properties:
          gatewayName: example_value
    

    Create Gateway Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Gateway(name: string, args: GatewayArgs, opts?: CustomResourceOptions);
    @overload
    def Gateway(resource_name: str,
                args: GatewayArgs,
                opts: Optional[ResourceOptions] = None)
    
    @overload
    def Gateway(resource_name: str,
                opts: Optional[ResourceOptions] = None,
                gateway_name: Optional[str] = None,
                gateway_desc: Optional[str] = None)
    func NewGateway(ctx *Context, name string, args GatewayArgs, opts ...ResourceOption) (*Gateway, error)
    public Gateway(string name, GatewayArgs args, CustomResourceOptions? opts = null)
    public Gateway(String name, GatewayArgs args)
    public Gateway(String name, GatewayArgs args, CustomResourceOptions options)
    
    type: alicloud:databasegateway:Gateway
    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 GatewayArgs
    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 GatewayArgs
    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 GatewayArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args GatewayArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args GatewayArgs
    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 alicloudGatewayResource = new AliCloud.DatabaseGateway.Gateway("alicloudGatewayResource", new()
    {
        GatewayName = "string",
        GatewayDesc = "string",
    });
    
    example, err := databasegateway.NewGateway(ctx, "alicloudGatewayResource", &databasegateway.GatewayArgs{
    	GatewayName: pulumi.String("string"),
    	GatewayDesc: pulumi.String("string"),
    })
    
    var alicloudGatewayResource = new Gateway("alicloudGatewayResource", GatewayArgs.builder()
        .gatewayName("string")
        .gatewayDesc("string")
        .build());
    
    alicloud_gateway_resource = alicloud.databasegateway.Gateway("alicloudGatewayResource",
        gateway_name="string",
        gateway_desc="string")
    
    const alicloudGatewayResource = new alicloud.databasegateway.Gateway("alicloudGatewayResource", {
        gatewayName: "string",
        gatewayDesc: "string",
    });
    
    type: alicloud:databasegateway:Gateway
    properties:
        gatewayDesc: string
        gatewayName: string
    

    Gateway Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The Gateway resource accepts the following input properties:

    GatewayName string
    The name of the Gateway.
    GatewayDesc string
    The description of Gateway.
    GatewayName string
    The name of the Gateway.
    GatewayDesc string
    The description of Gateway.
    gatewayName String
    The name of the Gateway.
    gatewayDesc String
    The description of Gateway.
    gatewayName string
    The name of the Gateway.
    gatewayDesc string
    The description of Gateway.
    gateway_name str
    The name of the Gateway.
    gateway_desc str
    The description of Gateway.
    gatewayName String
    The name of the Gateway.
    gatewayDesc String
    The description of Gateway.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Gateway resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    id string
    The provider-assigned unique ID for this managed resource.
    status string
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    id str
    The provider-assigned unique ID for this managed resource.
    status str
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.

    Look up Existing Gateway Resource

    Get an existing Gateway 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?: GatewayState, opts?: CustomResourceOptions): Gateway
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            gateway_desc: Optional[str] = None,
            gateway_name: Optional[str] = None,
            status: Optional[str] = None) -> Gateway
    func GetGateway(ctx *Context, name string, id IDInput, state *GatewayState, opts ...ResourceOption) (*Gateway, error)
    public static Gateway Get(string name, Input<string> id, GatewayState? state, CustomResourceOptions? opts = null)
    public static Gateway get(String name, Output<String> id, GatewayState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    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.
    The following state arguments are supported:
    GatewayDesc string
    The description of Gateway.
    GatewayName string
    The name of the Gateway.
    Status string
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    GatewayDesc string
    The description of Gateway.
    GatewayName string
    The name of the Gateway.
    Status string
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    gatewayDesc String
    The description of Gateway.
    gatewayName String
    The name of the Gateway.
    status String
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    gatewayDesc string
    The description of Gateway.
    gatewayName string
    The name of the Gateway.
    status string
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    gateway_desc str
    The description of Gateway.
    gateway_name str
    The name of the Gateway.
    status str
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.
    gatewayDesc String
    The description of Gateway.
    gatewayName String
    The name of the Gateway.
    status String
    The status of gateway. Valid values: EXCEPTION, NEW, RUNNING, STOPPED.

    Import

    Database Gateway Gateway can be imported using the id, e.g.

    $ pulumi import alicloud:databasegateway/gateway:Gateway example <id>
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo
    Alibaba Cloud v3.59.0 published on Friday, Jul 12, 2024 by Pulumi