tencentcloud.PostgresqlParameterTemplate
Explore with Pulumi AI
Provides a resource to create a postgresql parameter_template
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const parameterTemplate = new tencentcloud.PostgresqlParameterTemplate("parameterTemplate", {
    dbEngine: "postgresql",
    dbMajorVersion: "13",
    deleteParamSets: ["lc_time"],
    modifyParamEntrySets: [
        {
            expectedValue: "UTC",
            name: "timezone",
        },
        {
            expectedValue: "123",
            name: "lock_timeout",
        },
    ],
    templateDescription: "For_tf_test",
    templateName: "your_temp_name",
});
import pulumi
import pulumi_tencentcloud as tencentcloud
parameter_template = tencentcloud.PostgresqlParameterTemplate("parameterTemplate",
    db_engine="postgresql",
    db_major_version="13",
    delete_param_sets=["lc_time"],
    modify_param_entry_sets=[
        {
            "expected_value": "UTC",
            "name": "timezone",
        },
        {
            "expected_value": "123",
            "name": "lock_timeout",
        },
    ],
    template_description="For_tf_test",
    template_name="your_temp_name")
package main
import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := tencentcloud.NewPostgresqlParameterTemplate(ctx, "parameterTemplate", &tencentcloud.PostgresqlParameterTemplateArgs{
			DbEngine:       pulumi.String("postgresql"),
			DbMajorVersion: pulumi.String("13"),
			DeleteParamSets: pulumi.StringArray{
				pulumi.String("lc_time"),
			},
			ModifyParamEntrySets: tencentcloud.PostgresqlParameterTemplateModifyParamEntrySetArray{
				&tencentcloud.PostgresqlParameterTemplateModifyParamEntrySetArgs{
					ExpectedValue: pulumi.String("UTC"),
					Name:          pulumi.String("timezone"),
				},
				&tencentcloud.PostgresqlParameterTemplateModifyParamEntrySetArgs{
					ExpectedValue: pulumi.String("123"),
					Name:          pulumi.String("lock_timeout"),
				},
			},
			TemplateDescription: pulumi.String("For_tf_test"),
			TemplateName:        pulumi.String("your_temp_name"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() => 
{
    var parameterTemplate = new Tencentcloud.PostgresqlParameterTemplate("parameterTemplate", new()
    {
        DbEngine = "postgresql",
        DbMajorVersion = "13",
        DeleteParamSets = new[]
        {
            "lc_time",
        },
        ModifyParamEntrySets = new[]
        {
            new Tencentcloud.Inputs.PostgresqlParameterTemplateModifyParamEntrySetArgs
            {
                ExpectedValue = "UTC",
                Name = "timezone",
            },
            new Tencentcloud.Inputs.PostgresqlParameterTemplateModifyParamEntrySetArgs
            {
                ExpectedValue = "123",
                Name = "lock_timeout",
            },
        },
        TemplateDescription = "For_tf_test",
        TemplateName = "your_temp_name",
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.PostgresqlParameterTemplate;
import com.pulumi.tencentcloud.PostgresqlParameterTemplateArgs;
import com.pulumi.tencentcloud.inputs.PostgresqlParameterTemplateModifyParamEntrySetArgs;
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 parameterTemplate = new PostgresqlParameterTemplate("parameterTemplate", PostgresqlParameterTemplateArgs.builder()
            .dbEngine("postgresql")
            .dbMajorVersion("13")
            .deleteParamSets("lc_time")
            .modifyParamEntrySets(            
                PostgresqlParameterTemplateModifyParamEntrySetArgs.builder()
                    .expectedValue("UTC")
                    .name("timezone")
                    .build(),
                PostgresqlParameterTemplateModifyParamEntrySetArgs.builder()
                    .expectedValue("123")
                    .name("lock_timeout")
                    .build())
            .templateDescription("For_tf_test")
            .templateName("your_temp_name")
            .build());
    }
}
resources:
  parameterTemplate:
    type: tencentcloud:PostgresqlParameterTemplate
    properties:
      dbEngine: postgresql
      dbMajorVersion: '13'
      deleteParamSets:
        - lc_time
      modifyParamEntrySets:
        - expectedValue: UTC
          name: timezone
        - expectedValue: '123'
          name: lock_timeout
      templateDescription: For_tf_test
      templateName: your_temp_name
Create PostgresqlParameterTemplate Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new PostgresqlParameterTemplate(name: string, args: PostgresqlParameterTemplateArgs, opts?: CustomResourceOptions);@overload
def PostgresqlParameterTemplate(resource_name: str,
                                args: PostgresqlParameterTemplateArgs,
                                opts: Optional[ResourceOptions] = None)
@overload
def PostgresqlParameterTemplate(resource_name: str,
                                opts: Optional[ResourceOptions] = None,
                                db_engine: Optional[str] = None,
                                db_major_version: Optional[str] = None,
                                template_name: Optional[str] = None,
                                delete_param_sets: Optional[Sequence[str]] = None,
                                modify_param_entry_sets: Optional[Sequence[PostgresqlParameterTemplateModifyParamEntrySetArgs]] = None,
                                postgresql_parameter_template_id: Optional[str] = None,
                                template_description: Optional[str] = None)func NewPostgresqlParameterTemplate(ctx *Context, name string, args PostgresqlParameterTemplateArgs, opts ...ResourceOption) (*PostgresqlParameterTemplate, error)public PostgresqlParameterTemplate(string name, PostgresqlParameterTemplateArgs args, CustomResourceOptions? opts = null)
public PostgresqlParameterTemplate(String name, PostgresqlParameterTemplateArgs args)
public PostgresqlParameterTemplate(String name, PostgresqlParameterTemplateArgs args, CustomResourceOptions options)
type: tencentcloud:PostgresqlParameterTemplate
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 PostgresqlParameterTemplateArgs
- 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 PostgresqlParameterTemplateArgs
- 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 PostgresqlParameterTemplateArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args PostgresqlParameterTemplateArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args PostgresqlParameterTemplateArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
PostgresqlParameterTemplate Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The PostgresqlParameterTemplate resource accepts the following input properties:
- DbEngine string
- Database engine, such as postgresql, mssql_compatible.
- DbMajor stringVersion 
- The major database version number, such as 11, 12, 13.
- TemplateName string
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- DeleteParam List<string>Sets 
- The set of parameters that need to be deleted.
- ModifyParam List<PostgresqlEntry Sets Parameter Template Modify Param Entry Set> 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- PostgresqlParameter stringTemplate Id 
- ID of the resource.
- TemplateDescription string
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- DbEngine string
- Database engine, such as postgresql, mssql_compatible.
- DbMajor stringVersion 
- The major database version number, such as 11, 12, 13.
- TemplateName string
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- DeleteParam []stringSets 
- The set of parameters that need to be deleted.
- ModifyParam []PostgresqlEntry Sets Parameter Template Modify Param Entry Set Args 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- PostgresqlParameter stringTemplate Id 
- ID of the resource.
- TemplateDescription string
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- dbEngine String
- Database engine, such as postgresql, mssql_compatible.
- dbMajor StringVersion 
- The major database version number, such as 11, 12, 13.
- templateName String
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- deleteParam List<String>Sets 
- The set of parameters that need to be deleted.
- modifyParam List<PostgresqlEntry Sets Parameter Template Modify Param Entry Set> 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- postgresqlParameter StringTemplate Id 
- ID of the resource.
- templateDescription String
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- dbEngine string
- Database engine, such as postgresql, mssql_compatible.
- dbMajor stringVersion 
- The major database version number, such as 11, 12, 13.
- templateName string
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- deleteParam string[]Sets 
- The set of parameters that need to be deleted.
- modifyParam PostgresqlEntry Sets Parameter Template Modify Param Entry Set[] 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- postgresqlParameter stringTemplate Id 
- ID of the resource.
- templateDescription string
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- db_engine str
- Database engine, such as postgresql, mssql_compatible.
- db_major_ strversion 
- The major database version number, such as 11, 12, 13.
- template_name str
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- delete_param_ Sequence[str]sets 
- The set of parameters that need to be deleted.
- modify_param_ Sequence[Postgresqlentry_ sets Parameter Template Modify Param Entry Set Args] 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- postgresql_parameter_ strtemplate_ id 
- ID of the resource.
- template_description str
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- dbEngine String
- Database engine, such as postgresql, mssql_compatible.
- dbMajor StringVersion 
- The major database version number, such as 11, 12, 13.
- templateName String
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- deleteParam List<String>Sets 
- The set of parameters that need to be deleted.
- modifyParam List<Property Map>Entry Sets 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- postgresqlParameter StringTemplate Id 
- ID of the resource.
- templateDescription String
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
Outputs
All input properties are implicitly available as output properties. Additionally, the PostgresqlParameterTemplate 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 PostgresqlParameterTemplate Resource
Get an existing PostgresqlParameterTemplate 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?: PostgresqlParameterTemplateState, opts?: CustomResourceOptions): PostgresqlParameterTemplate@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        db_engine: Optional[str] = None,
        db_major_version: Optional[str] = None,
        delete_param_sets: Optional[Sequence[str]] = None,
        modify_param_entry_sets: Optional[Sequence[PostgresqlParameterTemplateModifyParamEntrySetArgs]] = None,
        postgresql_parameter_template_id: Optional[str] = None,
        template_description: Optional[str] = None,
        template_name: Optional[str] = None) -> PostgresqlParameterTemplatefunc GetPostgresqlParameterTemplate(ctx *Context, name string, id IDInput, state *PostgresqlParameterTemplateState, opts ...ResourceOption) (*PostgresqlParameterTemplate, error)public static PostgresqlParameterTemplate Get(string name, Input<string> id, PostgresqlParameterTemplateState? state, CustomResourceOptions? opts = null)public static PostgresqlParameterTemplate get(String name, Output<String> id, PostgresqlParameterTemplateState state, CustomResourceOptions options)resources:  _:    type: tencentcloud:PostgresqlParameterTemplate    get:      id: ${id}- 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.
- DbEngine string
- Database engine, such as postgresql, mssql_compatible.
- DbMajor stringVersion 
- The major database version number, such as 11, 12, 13.
- DeleteParam List<string>Sets 
- The set of parameters that need to be deleted.
- ModifyParam List<PostgresqlEntry Sets Parameter Template Modify Param Entry Set> 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- PostgresqlParameter stringTemplate Id 
- ID of the resource.
- TemplateDescription string
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- TemplateName string
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- DbEngine string
- Database engine, such as postgresql, mssql_compatible.
- DbMajor stringVersion 
- The major database version number, such as 11, 12, 13.
- DeleteParam []stringSets 
- The set of parameters that need to be deleted.
- ModifyParam []PostgresqlEntry Sets Parameter Template Modify Param Entry Set Args 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- PostgresqlParameter stringTemplate Id 
- ID of the resource.
- TemplateDescription string
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- TemplateName string
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- dbEngine String
- Database engine, such as postgresql, mssql_compatible.
- dbMajor StringVersion 
- The major database version number, such as 11, 12, 13.
- deleteParam List<String>Sets 
- The set of parameters that need to be deleted.
- modifyParam List<PostgresqlEntry Sets Parameter Template Modify Param Entry Set> 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- postgresqlParameter StringTemplate Id 
- ID of the resource.
- templateDescription String
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- templateName String
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- dbEngine string
- Database engine, such as postgresql, mssql_compatible.
- dbMajor stringVersion 
- The major database version number, such as 11, 12, 13.
- deleteParam string[]Sets 
- The set of parameters that need to be deleted.
- modifyParam PostgresqlEntry Sets Parameter Template Modify Param Entry Set[] 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- postgresqlParameter stringTemplate Id 
- ID of the resource.
- templateDescription string
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- templateName string
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- db_engine str
- Database engine, such as postgresql, mssql_compatible.
- db_major_ strversion 
- The major database version number, such as 11, 12, 13.
- delete_param_ Sequence[str]sets 
- The set of parameters that need to be deleted.
- modify_param_ Sequence[Postgresqlentry_ sets Parameter Template Modify Param Entry Set Args] 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- postgresql_parameter_ strtemplate_ id 
- ID of the resource.
- template_description str
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- template_name str
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- dbEngine String
- Database engine, such as postgresql, mssql_compatible.
- dbMajor StringVersion 
- The major database version number, such as 11, 12, 13.
- deleteParam List<String>Sets 
- The set of parameters that need to be deleted.
- modifyParam List<Property Map>Entry Sets 
- The set of parameters that need to be modified or added. Note: the same parameter cannot appear in the set of modifying and adding and deleting at the same time.
- postgresqlParameter StringTemplate Id 
- ID of the resource.
- templateDescription String
- Parameter template description, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
- templateName String
- Template name, which can contain 1-60 letters, digits, and symbols (-_./()+=:@).
Supporting Types
PostgresqlParameterTemplateModifyParamEntrySet, PostgresqlParameterTemplateModifyParamEntrySetArgs              
- ExpectedValue string
- Modify the parameter value. The input parameters are passed in the form of strings, for example: decimal 0.1, integer1000, enumerationreplica.
- Name string
- The parameter name.
- ExpectedValue string
- Modify the parameter value. The input parameters are passed in the form of strings, for example: decimal 0.1, integer1000, enumerationreplica.
- Name string
- The parameter name.
- expectedValue String
- Modify the parameter value. The input parameters are passed in the form of strings, for example: decimal 0.1, integer1000, enumerationreplica.
- name String
- The parameter name.
- expectedValue string
- Modify the parameter value. The input parameters are passed in the form of strings, for example: decimal 0.1, integer1000, enumerationreplica.
- name string
- The parameter name.
- expected_value str
- Modify the parameter value. The input parameters are passed in the form of strings, for example: decimal 0.1, integer1000, enumerationreplica.
- name str
- The parameter name.
- expectedValue String
- Modify the parameter value. The input parameters are passed in the form of strings, for example: decimal 0.1, integer1000, enumerationreplica.
- name String
- The parameter name.
Import
postgresql parameter_template can be imported using the id, e.g.
Notice: modify_param_entry_set and delete_param_set do not support import.
$ pulumi import tencentcloud:index/postgresqlParameterTemplate:PostgresqlParameterTemplate parameter_template parameter_template_id
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- tencentcloud tencentcloudstack/terraform-provider-tencentcloud
- License
- Notes
- This Pulumi package is based on the tencentcloudTerraform Provider.