@volcengine/pulumi
Version:
A Pulumi package for creating and managing volcengine cloud resources.
155 lines (154 loc) • 7.33 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* Provides a resource to manage rds postgresql account
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as volcengine from "@volcengine/pulumi";
*
* const foo = new volcengine.rds_postgresql.Account("foo", {
* accountName: "acc-test-account",
* accountPassword: "93c@*****!ab12",
* accountType: "Super",
* instanceId: "postgres-0ac38a79fe35",
* });
* const foo1 = new volcengine.rds_postgresql.Account("foo1", {
* accountName: "acc-test-account1",
* accountPassword: "9wc@****b12",
* accountPrivileges: "Login,Inherit",
* accountType: "Normal",
* instanceId: "postgres-0ac38a79fe35",
* notAllowPrivileges: ["DDL"],
* });
* ```
*
* ## Import
*
* RDS postgresql account can be imported using the instance_id:account_name, e.g.
*
* ```sh
* $ pulumi import volcengine:rds_postgresql/account:Account default postgres-ca7b7019****:accountName
* ```
*/
export declare class Account extends pulumi.CustomResource {
/**
* Get an existing Account 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?: AccountState, opts?: pulumi.CustomResourceOptions): Account;
/**
* Returns true if the given object is an instance of Account. 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 Account;
/**
* Database account name.
*/
readonly accountName: pulumi.Output<string>;
/**
* The password of the database account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignoreChanges ignore changes in fields.
*/
readonly accountPassword: pulumi.Output<string>;
/**
* The privilege information of account. When the account type is a super account, there is no need to pass in this parameter, and all privileges are supported by default. When the account type is a normal account, this parameter can be passed in, the default values are Login and Inherit.When the account type is an instance read-only account, this parameter is not required to be passed in, as this account type does not support permission granting.
*/
readonly accountPrivileges: pulumi.Output<string | undefined>;
/**
* The status of the database account.
*/
readonly accountStatus: pulumi.Output<string>;
/**
* Database account type, value:
* Super: A high-privilege account. Only one database account can be created for an instance.
* Normal: An account with ordinary privileges.
*/
readonly accountType: pulumi.Output<string>;
/**
* The ID of the RDS instance.
*/
readonly instanceId: pulumi.Output<string>;
/**
* The permissions to be disabled for the account. Only the DDL permission is supported for the moment. This field can only be passed in for high-privilege accounts or normal accounts, i.e., when the accountType is set to Super or Normal.
*/
readonly notAllowPrivileges: pulumi.Output<string[] | undefined>;
/**
* Create a Account 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: AccountArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering Account resources.
*/
export interface AccountState {
/**
* Database account name.
*/
accountName?: pulumi.Input<string>;
/**
* The password of the database account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignoreChanges ignore changes in fields.
*/
accountPassword?: pulumi.Input<string>;
/**
* The privilege information of account. When the account type is a super account, there is no need to pass in this parameter, and all privileges are supported by default. When the account type is a normal account, this parameter can be passed in, the default values are Login and Inherit.When the account type is an instance read-only account, this parameter is not required to be passed in, as this account type does not support permission granting.
*/
accountPrivileges?: pulumi.Input<string>;
/**
* The status of the database account.
*/
accountStatus?: pulumi.Input<string>;
/**
* Database account type, value:
* Super: A high-privilege account. Only one database account can be created for an instance.
* Normal: An account with ordinary privileges.
*/
accountType?: pulumi.Input<string>;
/**
* The ID of the RDS instance.
*/
instanceId?: pulumi.Input<string>;
/**
* The permissions to be disabled for the account. Only the DDL permission is supported for the moment. This field can only be passed in for high-privilege accounts or normal accounts, i.e., when the accountType is set to Super or Normal.
*/
notAllowPrivileges?: pulumi.Input<pulumi.Input<string>[]>;
}
/**
* The set of arguments for constructing a Account resource.
*/
export interface AccountArgs {
/**
* Database account name.
*/
accountName: pulumi.Input<string>;
/**
* The password of the database account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignoreChanges ignore changes in fields.
*/
accountPassword: pulumi.Input<string>;
/**
* The privilege information of account. When the account type is a super account, there is no need to pass in this parameter, and all privileges are supported by default. When the account type is a normal account, this parameter can be passed in, the default values are Login and Inherit.When the account type is an instance read-only account, this parameter is not required to be passed in, as this account type does not support permission granting.
*/
accountPrivileges?: pulumi.Input<string>;
/**
* Database account type, value:
* Super: A high-privilege account. Only one database account can be created for an instance.
* Normal: An account with ordinary privileges.
*/
accountType: pulumi.Input<string>;
/**
* The ID of the RDS instance.
*/
instanceId: pulumi.Input<string>;
/**
* The permissions to be disabled for the account. Only the DDL permission is supported for the moment. This field can only be passed in for high-privilege accounts or normal accounts, i.e., when the accountType is set to Super or Normal.
*/
notAllowPrivileges?: pulumi.Input<pulumi.Input<string>[]>;
}