1. Packages
  2. Volcengine
  3. API Docs
  4. rds_postgresql
  5. Schema
Volcengine v0.0.26 published on Friday, Sep 13, 2024 by Volcengine

volcengine.rds_postgresql.Schema

Explore with Pulumi AI

volcengine logo
Volcengine v0.0.26 published on Friday, Sep 13, 2024 by Volcengine

    Provides a resource to manage rds postgresql schema

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Volcengine = Pulumi.Volcengine;
    
    return await Deployment.RunAsync(() => 
    {
        var fooZones = Volcengine.Ecs.Zones.Invoke();
    
        var fooVpc = new Volcengine.Vpc.Vpc("fooVpc", new()
        {
            VpcName = "acc-test-project1",
            CidrBlock = "172.16.0.0/16",
        });
    
        var fooSubnet = new Volcengine.Vpc.Subnet("fooSubnet", new()
        {
            SubnetName = "acc-subnet-test-2",
            CidrBlock = "172.16.0.0/24",
            ZoneId = fooZones.Apply(zonesResult => zonesResult.Zones[0]?.Id),
            VpcId = fooVpc.Id,
        });
    
        var fooInstance = new Volcengine.Rds_postgresql.Instance("fooInstance", new()
        {
            DbEngineVersion = "PostgreSQL_12",
            NodeSpec = "rds.postgres.1c2g",
            PrimaryZoneId = fooZones.Apply(zonesResult => zonesResult.Zones[0]?.Id),
            SecondaryZoneId = fooZones.Apply(zonesResult => zonesResult.Zones[0]?.Id),
            StorageSpace = 40,
            SubnetId = fooSubnet.Id,
            InstanceName = "acc-test-1",
            ChargeInfo = new Volcengine.Rds_postgresql.Inputs.InstanceChargeInfoArgs
            {
                ChargeType = "PostPaid",
            },
            ProjectName = "default",
            Tags = new[]
            {
                new Volcengine.Rds_postgresql.Inputs.InstanceTagArgs
                {
                    Key = "tfk1",
                    Value = "tfv1",
                },
            },
            Parameters = new[]
            {
                new Volcengine.Rds_postgresql.Inputs.InstanceParameterArgs
                {
                    Name = "auto_explain.log_analyze",
                    Value = "off",
                },
                new Volcengine.Rds_postgresql.Inputs.InstanceParameterArgs
                {
                    Name = "auto_explain.log_format",
                    Value = "text",
                },
            },
        });
    
        var fooDatabase = new Volcengine.Rds_postgresql.Database("fooDatabase", new()
        {
            DbName = "acc-test",
            InstanceId = fooInstance.Id,
            CType = "C",
            Collate = "zh_CN.utf8",
        });
    
        var fooAccount = new Volcengine.Rds_postgresql.Account("fooAccount", new()
        {
            AccountName = "acc-test-account",
            AccountPassword = "9wc@********12",
            AccountType = "Normal",
            InstanceId = fooInstance.Id,
            AccountPrivileges = "Inherit,Login,CreateRole,CreateDB",
        });
    
        var foo1 = new Volcengine.Rds_postgresql.Account("foo1", new()
        {
            AccountName = "acc-test-account1",
            AccountPassword = "9wc@*******12",
            AccountType = "Normal",
            InstanceId = fooInstance.Id,
            AccountPrivileges = "Inherit,Login,CreateRole,CreateDB",
        });
    
        var fooSchema = new Volcengine.Rds_postgresql.Schema("fooSchema", new()
        {
            DbName = fooDatabase.DbName,
            InstanceId = fooInstance.Id,
            Owner = fooAccount.AccountName,
            SchemaName = "acc-test-schema",
        });
    
    });
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/ecs"
    	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/rds_postgresql"
    	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/vpc"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		fooZones, err := ecs.Zones(ctx, nil, nil)
    		if err != nil {
    			return err
    		}
    		fooVpc, err := vpc.NewVpc(ctx, "fooVpc", &vpc.VpcArgs{
    			VpcName:   pulumi.String("acc-test-project1"),
    			CidrBlock: pulumi.String("172.16.0.0/16"),
    		})
    		if err != nil {
    			return err
    		}
    		fooSubnet, err := vpc.NewSubnet(ctx, "fooSubnet", &vpc.SubnetArgs{
    			SubnetName: pulumi.String("acc-subnet-test-2"),
    			CidrBlock:  pulumi.String("172.16.0.0/24"),
    			ZoneId:     *pulumi.String(fooZones.Zones[0].Id),
    			VpcId:      fooVpc.ID(),
    		})
    		if err != nil {
    			return err
    		}
    		fooInstance, err := rds_postgresql.NewInstance(ctx, "fooInstance", &rds_postgresql.InstanceArgs{
    			DbEngineVersion: pulumi.String("PostgreSQL_12"),
    			NodeSpec:        pulumi.String("rds.postgres.1c2g"),
    			PrimaryZoneId:   *pulumi.String(fooZones.Zones[0].Id),
    			SecondaryZoneId: *pulumi.String(fooZones.Zones[0].Id),
    			StorageSpace:    pulumi.Int(40),
    			SubnetId:        fooSubnet.ID(),
    			InstanceName:    pulumi.String("acc-test-1"),
    			ChargeInfo: &rds_postgresql.InstanceChargeInfoArgs{
    				ChargeType: pulumi.String("PostPaid"),
    			},
    			ProjectName: pulumi.String("default"),
    			Tags: rds_postgresql.InstanceTagArray{
    				&rds_postgresql.InstanceTagArgs{
    					Key:   pulumi.String("tfk1"),
    					Value: pulumi.String("tfv1"),
    				},
    			},
    			Parameters: rds_postgresql.InstanceParameterArray{
    				&rds_postgresql.InstanceParameterArgs{
    					Name:  pulumi.String("auto_explain.log_analyze"),
    					Value: pulumi.String("off"),
    				},
    				&rds_postgresql.InstanceParameterArgs{
    					Name:  pulumi.String("auto_explain.log_format"),
    					Value: pulumi.String("text"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		fooDatabase, err := rds_postgresql.NewDatabase(ctx, "fooDatabase", &rds_postgresql.DatabaseArgs{
    			DbName:     pulumi.String("acc-test"),
    			InstanceId: fooInstance.ID(),
    			CType:      pulumi.String("C"),
    			Collate:    pulumi.String("zh_CN.utf8"),
    		})
    		if err != nil {
    			return err
    		}
    		fooAccount, err := rds_postgresql.NewAccount(ctx, "fooAccount", &rds_postgresql.AccountArgs{
    			AccountName:       pulumi.String("acc-test-account"),
    			AccountPassword:   pulumi.String("9wc@********12"),
    			AccountType:       pulumi.String("Normal"),
    			InstanceId:        fooInstance.ID(),
    			AccountPrivileges: pulumi.String("Inherit,Login,CreateRole,CreateDB"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = rds_postgresql.NewAccount(ctx, "foo1", &rds_postgresql.AccountArgs{
    			AccountName:       pulumi.String("acc-test-account1"),
    			AccountPassword:   pulumi.String("9wc@*******12"),
    			AccountType:       pulumi.String("Normal"),
    			InstanceId:        fooInstance.ID(),
    			AccountPrivileges: pulumi.String("Inherit,Login,CreateRole,CreateDB"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = rds_postgresql.NewSchema(ctx, "fooSchema", &rds_postgresql.SchemaArgs{
    			DbName:     fooDatabase.DbName,
    			InstanceId: fooInstance.ID(),
    			Owner:      fooAccount.AccountName,
    			SchemaName: pulumi.String("acc-test-schema"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.volcengine.ecs.EcsFunctions;
    import com.pulumi.volcengine.ecs.inputs.ZonesArgs;
    import com.pulumi.volcengine.vpc.Vpc;
    import com.pulumi.volcengine.vpc.VpcArgs;
    import com.pulumi.volcengine.vpc.Subnet;
    import com.pulumi.volcengine.vpc.SubnetArgs;
    import com.pulumi.volcengine.rds_postgresql.Instance;
    import com.pulumi.volcengine.rds_postgresql.InstanceArgs;
    import com.pulumi.volcengine.rds_postgresql.inputs.InstanceChargeInfoArgs;
    import com.pulumi.volcengine.rds_postgresql.inputs.InstanceTagArgs;
    import com.pulumi.volcengine.rds_postgresql.inputs.InstanceParameterArgs;
    import com.pulumi.volcengine.rds_postgresql.Database;
    import com.pulumi.volcengine.rds_postgresql.DatabaseArgs;
    import com.pulumi.volcengine.rds_postgresql.Account;
    import com.pulumi.volcengine.rds_postgresql.AccountArgs;
    import com.pulumi.volcengine.rds_postgresql.Schema;
    import com.pulumi.volcengine.rds_postgresql.SchemaArgs;
    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) {
            final var fooZones = EcsFunctions.Zones();
    
            var fooVpc = new Vpc("fooVpc", VpcArgs.builder()        
                .vpcName("acc-test-project1")
                .cidrBlock("172.16.0.0/16")
                .build());
    
            var fooSubnet = new Subnet("fooSubnet", SubnetArgs.builder()        
                .subnetName("acc-subnet-test-2")
                .cidrBlock("172.16.0.0/24")
                .zoneId(fooZones.applyValue(zonesResult -> zonesResult.zones()[0].id()))
                .vpcId(fooVpc.id())
                .build());
    
            var fooInstance = new Instance("fooInstance", InstanceArgs.builder()        
                .dbEngineVersion("PostgreSQL_12")
                .nodeSpec("rds.postgres.1c2g")
                .primaryZoneId(fooZones.applyValue(zonesResult -> zonesResult.zones()[0].id()))
                .secondaryZoneId(fooZones.applyValue(zonesResult -> zonesResult.zones()[0].id()))
                .storageSpace(40)
                .subnetId(fooSubnet.id())
                .instanceName("acc-test-1")
                .chargeInfo(InstanceChargeInfoArgs.builder()
                    .chargeType("PostPaid")
                    .build())
                .projectName("default")
                .tags(InstanceTagArgs.builder()
                    .key("tfk1")
                    .value("tfv1")
                    .build())
                .parameters(            
                    InstanceParameterArgs.builder()
                        .name("auto_explain.log_analyze")
                        .value("off")
                        .build(),
                    InstanceParameterArgs.builder()
                        .name("auto_explain.log_format")
                        .value("text")
                        .build())
                .build());
    
            var fooDatabase = new Database("fooDatabase", DatabaseArgs.builder()        
                .dbName("acc-test")
                .instanceId(fooInstance.id())
                .cType("C")
                .collate("zh_CN.utf8")
                .build());
    
            var fooAccount = new Account("fooAccount", AccountArgs.builder()        
                .accountName("acc-test-account")
                .accountPassword("9wc@********12")
                .accountType("Normal")
                .instanceId(fooInstance.id())
                .accountPrivileges("Inherit,Login,CreateRole,CreateDB")
                .build());
    
            var foo1 = new Account("foo1", AccountArgs.builder()        
                .accountName("acc-test-account1")
                .accountPassword("9wc@*******12")
                .accountType("Normal")
                .instanceId(fooInstance.id())
                .accountPrivileges("Inherit,Login,CreateRole,CreateDB")
                .build());
    
            var fooSchema = new Schema("fooSchema", SchemaArgs.builder()        
                .dbName(fooDatabase.dbName())
                .instanceId(fooInstance.id())
                .owner(fooAccount.accountName())
                .schemaName("acc-test-schema")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_volcengine as volcengine
    
    foo_zones = volcengine.ecs.zones()
    foo_vpc = volcengine.vpc.Vpc("fooVpc",
        vpc_name="acc-test-project1",
        cidr_block="172.16.0.0/16")
    foo_subnet = volcengine.vpc.Subnet("fooSubnet",
        subnet_name="acc-subnet-test-2",
        cidr_block="172.16.0.0/24",
        zone_id=foo_zones.zones[0].id,
        vpc_id=foo_vpc.id)
    foo_instance = volcengine.rds_postgresql.Instance("fooInstance",
        db_engine_version="PostgreSQL_12",
        node_spec="rds.postgres.1c2g",
        primary_zone_id=foo_zones.zones[0].id,
        secondary_zone_id=foo_zones.zones[0].id,
        storage_space=40,
        subnet_id=foo_subnet.id,
        instance_name="acc-test-1",
        charge_info=volcengine.rds_postgresql.InstanceChargeInfoArgs(
            charge_type="PostPaid",
        ),
        project_name="default",
        tags=[volcengine.rds_postgresql.InstanceTagArgs(
            key="tfk1",
            value="tfv1",
        )],
        parameters=[
            volcengine.rds_postgresql.InstanceParameterArgs(
                name="auto_explain.log_analyze",
                value="off",
            ),
            volcengine.rds_postgresql.InstanceParameterArgs(
                name="auto_explain.log_format",
                value="text",
            ),
        ])
    foo_database = volcengine.rds_postgresql.Database("fooDatabase",
        db_name="acc-test",
        instance_id=foo_instance.id,
        c_type="C",
        collate="zh_CN.utf8")
    foo_account = volcengine.rds_postgresql.Account("fooAccount",
        account_name="acc-test-account",
        account_password="9wc@********12",
        account_type="Normal",
        instance_id=foo_instance.id,
        account_privileges="Inherit,Login,CreateRole,CreateDB")
    foo1 = volcengine.rds_postgresql.Account("foo1",
        account_name="acc-test-account1",
        account_password="9wc@*******12",
        account_type="Normal",
        instance_id=foo_instance.id,
        account_privileges="Inherit,Login,CreateRole,CreateDB")
    foo_schema = volcengine.rds_postgresql.Schema("fooSchema",
        db_name=foo_database.db_name,
        instance_id=foo_instance.id,
        owner=foo_account.account_name,
        schema_name="acc-test-schema")
    
    import * as pulumi from "@pulumi/pulumi";
    import * as volcengine from "@pulumi/volcengine";
    import * as volcengine from "@volcengine/pulumi";
    
    const fooZones = volcengine.ecs.Zones({});
    const fooVpc = new volcengine.vpc.Vpc("fooVpc", {
        vpcName: "acc-test-project1",
        cidrBlock: "172.16.0.0/16",
    });
    const fooSubnet = new volcengine.vpc.Subnet("fooSubnet", {
        subnetName: "acc-subnet-test-2",
        cidrBlock: "172.16.0.0/24",
        zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
        vpcId: fooVpc.id,
    });
    const fooInstance = new volcengine.rds_postgresql.Instance("fooInstance", {
        dbEngineVersion: "PostgreSQL_12",
        nodeSpec: "rds.postgres.1c2g",
        primaryZoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
        secondaryZoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
        storageSpace: 40,
        subnetId: fooSubnet.id,
        instanceName: "acc-test-1",
        chargeInfo: {
            chargeType: "PostPaid",
        },
        projectName: "default",
        tags: [{
            key: "tfk1",
            value: "tfv1",
        }],
        parameters: [
            {
                name: "auto_explain.log_analyze",
                value: "off",
            },
            {
                name: "auto_explain.log_format",
                value: "text",
            },
        ],
    });
    const fooDatabase = new volcengine.rds_postgresql.Database("fooDatabase", {
        dbName: "acc-test",
        instanceId: fooInstance.id,
        cType: "C",
        collate: "zh_CN.utf8",
    });
    const fooAccount = new volcengine.rds_postgresql.Account("fooAccount", {
        accountName: "acc-test-account",
        accountPassword: "9wc@********12",
        accountType: "Normal",
        instanceId: fooInstance.id,
        accountPrivileges: "Inherit,Login,CreateRole,CreateDB",
    });
    const foo1 = new volcengine.rds_postgresql.Account("foo1", {
        accountName: "acc-test-account1",
        accountPassword: "9wc@*******12",
        accountType: "Normal",
        instanceId: fooInstance.id,
        accountPrivileges: "Inherit,Login,CreateRole,CreateDB",
    });
    const fooSchema = new volcengine.rds_postgresql.Schema("fooSchema", {
        dbName: fooDatabase.dbName,
        instanceId: fooInstance.id,
        owner: fooAccount.accountName,
        schemaName: "acc-test-schema",
    });
    
    resources:
      fooVpc:
        type: volcengine:vpc:Vpc
        properties:
          vpcName: acc-test-project1
          cidrBlock: 172.16.0.0/16
      fooSubnet:
        type: volcengine:vpc:Subnet
        properties:
          subnetName: acc-subnet-test-2
          cidrBlock: 172.16.0.0/24
          zoneId: ${fooZones.zones[0].id}
          vpcId: ${fooVpc.id}
      fooInstance:
        type: volcengine:rds_postgresql:Instance
        properties:
          dbEngineVersion: PostgreSQL_12
          nodeSpec: rds.postgres.1c2g
          primaryZoneId: ${fooZones.zones[0].id}
          secondaryZoneId: ${fooZones.zones[0].id}
          storageSpace: 40
          subnetId: ${fooSubnet.id}
          instanceName: acc-test-1
          chargeInfo:
            chargeType: PostPaid
          projectName: default
          tags:
            - key: tfk1
              value: tfv1
          parameters:
            - name: auto_explain.log_analyze
              value: off
            - name: auto_explain.log_format
              value: text
      fooDatabase:
        type: volcengine:rds_postgresql:Database
        properties:
          dbName: acc-test
          instanceId: ${fooInstance.id}
          cType: C
          collate: zh_CN.utf8
      fooAccount:
        type: volcengine:rds_postgresql:Account
        properties:
          accountName: acc-test-account
          accountPassword: 9wc@********12
          accountType: Normal
          instanceId: ${fooInstance.id}
          accountPrivileges: Inherit,Login,CreateRole,CreateDB
      foo1:
        type: volcengine:rds_postgresql:Account
        properties:
          accountName: acc-test-account1
          accountPassword: 9wc@*******12
          accountType: Normal
          instanceId: ${fooInstance.id}
          accountPrivileges: Inherit,Login,CreateRole,CreateDB
      fooSchema:
        type: volcengine:rds_postgresql:Schema
        properties:
          dbName: ${fooDatabase.dbName}
          instanceId: ${fooInstance.id}
          owner: ${fooAccount.accountName}
          schemaName: acc-test-schema
    variables:
      fooZones:
        fn::invoke:
          Function: volcengine:ecs:Zones
          Arguments: {}
    

    Create Schema Resource

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

    Constructor syntax

    new Schema(name: string, args: SchemaArgs, opts?: CustomResourceOptions);
    @overload
    def Schema(resource_name: str,
               args: SchemaArgs,
               opts: Optional[ResourceOptions] = None)
    
    @overload
    def Schema(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               db_name: Optional[str] = None,
               instance_id: Optional[str] = None,
               owner: Optional[str] = None,
               schema_name: Optional[str] = None)
    func NewSchema(ctx *Context, name string, args SchemaArgs, opts ...ResourceOption) (*Schema, error)
    public Schema(string name, SchemaArgs args, CustomResourceOptions? opts = null)
    public Schema(String name, SchemaArgs args)
    public Schema(String name, SchemaArgs args, CustomResourceOptions options)
    
    type: volcengine:rds_postgresql:Schema
    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 SchemaArgs
    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 SchemaArgs
    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 SchemaArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SchemaArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SchemaArgs
    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 schemaResource = new Volcengine.Rds_postgresql.Schema("schemaResource", new()
    {
        DbName = "string",
        InstanceId = "string",
        Owner = "string",
        SchemaName = "string",
    });
    
    example, err := rds_postgresql.NewSchema(ctx, "schemaResource", &rds_postgresql.SchemaArgs{
    	DbName:     pulumi.String("string"),
    	InstanceId: pulumi.String("string"),
    	Owner:      pulumi.String("string"),
    	SchemaName: pulumi.String("string"),
    })
    
    var schemaResource = new Schema("schemaResource", SchemaArgs.builder()
        .dbName("string")
        .instanceId("string")
        .owner("string")
        .schemaName("string")
        .build());
    
    schema_resource = volcengine.rds_postgresql.Schema("schemaResource",
        db_name="string",
        instance_id="string",
        owner="string",
        schema_name="string")
    
    const schemaResource = new volcengine.rds_postgresql.Schema("schemaResource", {
        dbName: "string",
        instanceId: "string",
        owner: "string",
        schemaName: "string",
    });
    
    type: volcengine:rds_postgresql:Schema
    properties:
        dbName: string
        instanceId: string
        owner: string
        schemaName: string
    

    Schema 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 Schema resource accepts the following input properties:

    DbName string
    The name of the database.
    InstanceId string
    The id of the postgresql instance.
    Owner string
    The owner of the schema.
    SchemaName string
    The name of the schema.
    DbName string
    The name of the database.
    InstanceId string
    The id of the postgresql instance.
    Owner string
    The owner of the schema.
    SchemaName string
    The name of the schema.
    dbName String
    The name of the database.
    instanceId String
    The id of the postgresql instance.
    owner String
    The owner of the schema.
    schemaName String
    The name of the schema.
    dbName string
    The name of the database.
    instanceId string
    The id of the postgresql instance.
    owner string
    The owner of the schema.
    schemaName string
    The name of the schema.
    db_name str
    The name of the database.
    instance_id str
    The id of the postgresql instance.
    owner str
    The owner of the schema.
    schema_name str
    The name of the schema.
    dbName String
    The name of the database.
    instanceId String
    The id of the postgresql instance.
    owner String
    The owner of the schema.
    schemaName String
    The name of the schema.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Schema Resource

    Get an existing Schema 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?: SchemaState, opts?: CustomResourceOptions): Schema
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            db_name: Optional[str] = None,
            instance_id: Optional[str] = None,
            owner: Optional[str] = None,
            schema_name: Optional[str] = None) -> Schema
    func GetSchema(ctx *Context, name string, id IDInput, state *SchemaState, opts ...ResourceOption) (*Schema, error)
    public static Schema Get(string name, Input<string> id, SchemaState? state, CustomResourceOptions? opts = null)
    public static Schema get(String name, Output<String> id, SchemaState 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:
    DbName string
    The name of the database.
    InstanceId string
    The id of the postgresql instance.
    Owner string
    The owner of the schema.
    SchemaName string
    The name of the schema.
    DbName string
    The name of the database.
    InstanceId string
    The id of the postgresql instance.
    Owner string
    The owner of the schema.
    SchemaName string
    The name of the schema.
    dbName String
    The name of the database.
    instanceId String
    The id of the postgresql instance.
    owner String
    The owner of the schema.
    schemaName String
    The name of the schema.
    dbName string
    The name of the database.
    instanceId string
    The id of the postgresql instance.
    owner string
    The owner of the schema.
    schemaName string
    The name of the schema.
    db_name str
    The name of the database.
    instance_id str
    The id of the postgresql instance.
    owner str
    The owner of the schema.
    schema_name str
    The name of the schema.
    dbName String
    The name of the database.
    instanceId String
    The id of the postgresql instance.
    owner String
    The owner of the schema.
    schemaName String
    The name of the schema.

    Import

    RdsPostgresqlSchema can be imported using the instance id, database name and schema name, e.g.

     $ pulumi import volcengine:rds_postgresql/schema:Schema default instance_id:db_name:schema_name
    

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

    Package Details

    Repository
    volcengine volcengine/pulumi-volcengine
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the volcengine Terraform Provider.
    volcengine logo
    Volcengine v0.0.26 published on Friday, Sep 13, 2024 by Volcengine