@ediri/vultr
Version:
A Pulumi package for creating and managing Vultr cloud resources.
362 lines (361 loc) • 13.6 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* Provides a Vultr database replica resource. This can be used to create, read, modify, and delete managed database read replicas on your Vultr account.
*
* ## Example Usage
*
* Create a new database replica:
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as vultr from "@ediri/vultr";
*
* const myDatabaseReplica = new vultr.DatabaseReplica("myDatabaseReplica", {
* databaseId: vultr_database.my_database.id,
* region: "sea",
* label: "my_database_replica_label",
* tag: "test tag",
* });
* ```
*/
export declare class DatabaseReplica extends pulumi.CustomResource {
/**
* Get an existing DatabaseReplica 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?: DatabaseReplicaState, opts?: pulumi.CustomResourceOptions): DatabaseReplica;
/**
* Returns true if the given object is an instance of DatabaseReplica. 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 DatabaseReplica;
/**
* The configured time zone for the managed database read replica in TZ database format.
*/
readonly clusterTimeZone: pulumi.Output<string>;
/**
* The database engine of the managed database read replica.
*/
readonly databaseEngine: pulumi.Output<string>;
/**
* The database engine version of the managed database read replica.
*/
readonly databaseEngineVersion: pulumi.Output<string>;
/**
* The managed database ID you want to attach this replica to.
*/
readonly databaseId: pulumi.Output<string>;
/**
* The date the managed database read replica was added to your Vultr account.
*/
readonly dateCreated: pulumi.Output<string>;
/**
* The managed database read replica's default logical database.
*/
readonly dbname: pulumi.Output<string>;
/**
* The configuration value for the data eviction policy on the managed database read replica (Valkey engine types only).
*/
readonly evictionPolicy: pulumi.Output<string>;
/**
* An associated list of FerretDB connection credentials (FerretDB + PostgreSQL engine types only).
*/
readonly ferretdbCredentials: pulumi.Output<{
[key: string]: string;
}>;
/**
* The hostname assigned to the managed database read replica.
*/
readonly host: pulumi.Output<string>;
/**
* A label for the managed database read replica.
*/
readonly label: pulumi.Output<string>;
/**
* The date of the latest backup available on the managed database read replica.
*/
readonly latestBackup: pulumi.Output<string>;
/**
* The preferred maintenance day of week for the managed database read replica.
*/
readonly maintenanceDow: pulumi.Output<string>;
/**
* The preferred maintenance time for the managed database read replica.
*/
readonly maintenanceTime: pulumi.Output<string>;
/**
* The configuration value for the long query time (in seconds) on the managed database read replica (MySQL engine types only).
*/
readonly mysqlLongQueryTime: pulumi.Output<number>;
/**
* The configuration value for whether primary keys are required on the managed database read replica (MySQL engine types only).
*/
readonly mysqlRequirePrimaryKey: pulumi.Output<boolean>;
/**
* The configuration value for slow query logging on the managed database read replica (MySQL engine types only).
*/
readonly mysqlSlowQueryLog: pulumi.Output<boolean>;
/**
* A list of SQL modes currently configured for the managed database read replica (MySQL engine types only).
*/
readonly mysqlSqlModes: pulumi.Output<string[]>;
/**
* The password for the managed database read replica's primary admin user.
*/
readonly password: pulumi.Output<string>;
/**
* The managed database read replica's plan ID.
*/
readonly plan: pulumi.Output<string>;
/**
* The description of the disk(s) on the managed database read replica.
*/
readonly planDisk: pulumi.Output<number>;
/**
* The amount of memory available on the managed database read replica in MB.
*/
readonly planRam: pulumi.Output<number>;
/**
* The number of standby nodes available on the managed database read replica.
*/
readonly planReplicas: pulumi.Output<number>;
/**
* The number of virtual CPUs available on the managed database read replica.
*/
readonly planVcpus: pulumi.Output<number>;
/**
* The connection port for the managed database read replica.
*/
readonly port: pulumi.Output<string>;
/**
* The public hostname assigned to the managed database read replica (VPC-attached only).
*/
readonly publicHost: pulumi.Output<string>;
/**
* The ID of the region that the managed database read replica is to be created in. [See List Regions](https://www.vultr.com/api/#operation/list-regions)
*/
readonly region: pulumi.Output<string>;
/**
* The current status of the managed database read replica (poweroff, rebuilding, rebalancing, configuring, running).
*/
readonly status: pulumi.Output<string>;
/**
* The tag to assign to the managed database read replica.
*/
readonly tag: pulumi.Output<string>;
/**
* A list of allowed IP addresses for the managed database read replica.
*/
readonly trustedIps: pulumi.Output<string[]>;
/**
* The primary admin user for the managed database read replica.
*/
readonly user: pulumi.Output<string>;
/**
* The ID of the VPC Network attached to the managed database read replica.
*/
readonly vpcId: pulumi.Output<string>;
/**
* Create a DatabaseReplica 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: DatabaseReplicaArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering DatabaseReplica resources.
*/
export interface DatabaseReplicaState {
/**
* The configured time zone for the managed database read replica in TZ database format.
*/
clusterTimeZone?: pulumi.Input<string>;
/**
* The database engine of the managed database read replica.
*/
databaseEngine?: pulumi.Input<string>;
/**
* The database engine version of the managed database read replica.
*/
databaseEngineVersion?: pulumi.Input<string>;
/**
* The managed database ID you want to attach this replica to.
*/
databaseId?: pulumi.Input<string>;
/**
* The date the managed database read replica was added to your Vultr account.
*/
dateCreated?: pulumi.Input<string>;
/**
* The managed database read replica's default logical database.
*/
dbname?: pulumi.Input<string>;
/**
* The configuration value for the data eviction policy on the managed database read replica (Valkey engine types only).
*/
evictionPolicy?: pulumi.Input<string>;
/**
* An associated list of FerretDB connection credentials (FerretDB + PostgreSQL engine types only).
*/
ferretdbCredentials?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* The hostname assigned to the managed database read replica.
*/
host?: pulumi.Input<string>;
/**
* A label for the managed database read replica.
*/
label?: pulumi.Input<string>;
/**
* The date of the latest backup available on the managed database read replica.
*/
latestBackup?: pulumi.Input<string>;
/**
* The preferred maintenance day of week for the managed database read replica.
*/
maintenanceDow?: pulumi.Input<string>;
/**
* The preferred maintenance time for the managed database read replica.
*/
maintenanceTime?: pulumi.Input<string>;
/**
* The configuration value for the long query time (in seconds) on the managed database read replica (MySQL engine types only).
*/
mysqlLongQueryTime?: pulumi.Input<number>;
/**
* The configuration value for whether primary keys are required on the managed database read replica (MySQL engine types only).
*/
mysqlRequirePrimaryKey?: pulumi.Input<boolean>;
/**
* The configuration value for slow query logging on the managed database read replica (MySQL engine types only).
*/
mysqlSlowQueryLog?: pulumi.Input<boolean>;
/**
* A list of SQL modes currently configured for the managed database read replica (MySQL engine types only).
*/
mysqlSqlModes?: pulumi.Input<pulumi.Input<string>[]>;
/**
* The password for the managed database read replica's primary admin user.
*/
password?: pulumi.Input<string>;
/**
* The managed database read replica's plan ID.
*/
plan?: pulumi.Input<string>;
/**
* The description of the disk(s) on the managed database read replica.
*/
planDisk?: pulumi.Input<number>;
/**
* The amount of memory available on the managed database read replica in MB.
*/
planRam?: pulumi.Input<number>;
/**
* The number of standby nodes available on the managed database read replica.
*/
planReplicas?: pulumi.Input<number>;
/**
* The number of virtual CPUs available on the managed database read replica.
*/
planVcpus?: pulumi.Input<number>;
/**
* The connection port for the managed database read replica.
*/
port?: pulumi.Input<string>;
/**
* The public hostname assigned to the managed database read replica (VPC-attached only).
*/
publicHost?: pulumi.Input<string>;
/**
* The ID of the region that the managed database read replica is to be created in. [See List Regions](https://www.vultr.com/api/#operation/list-regions)
*/
region?: pulumi.Input<string>;
/**
* The current status of the managed database read replica (poweroff, rebuilding, rebalancing, configuring, running).
*/
status?: pulumi.Input<string>;
/**
* The tag to assign to the managed database read replica.
*/
tag?: pulumi.Input<string>;
/**
* A list of allowed IP addresses for the managed database read replica.
*/
trustedIps?: pulumi.Input<pulumi.Input<string>[]>;
/**
* The primary admin user for the managed database read replica.
*/
user?: pulumi.Input<string>;
/**
* The ID of the VPC Network attached to the managed database read replica.
*/
vpcId?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a DatabaseReplica resource.
*/
export interface DatabaseReplicaArgs {
/**
* The managed database ID you want to attach this replica to.
*/
databaseId: pulumi.Input<string>;
/**
* The configuration value for the data eviction policy on the managed database read replica (Valkey engine types only).
*/
evictionPolicy?: pulumi.Input<string>;
/**
* An associated list of FerretDB connection credentials (FerretDB + PostgreSQL engine types only).
*/
ferretdbCredentials?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* A label for the managed database read replica.
*/
label: pulumi.Input<string>;
/**
* The configuration value for the long query time (in seconds) on the managed database read replica (MySQL engine types only).
*/
mysqlLongQueryTime?: pulumi.Input<number>;
/**
* The configuration value for whether primary keys are required on the managed database read replica (MySQL engine types only).
*/
mysqlRequirePrimaryKey?: pulumi.Input<boolean>;
/**
* The configuration value for slow query logging on the managed database read replica (MySQL engine types only).
*/
mysqlSlowQueryLog?: pulumi.Input<boolean>;
/**
* A list of SQL modes currently configured for the managed database read replica (MySQL engine types only).
*/
mysqlSqlModes?: pulumi.Input<pulumi.Input<string>[]>;
/**
* The description of the disk(s) on the managed database read replica.
*/
planDisk?: pulumi.Input<number>;
/**
* The public hostname assigned to the managed database read replica (VPC-attached only).
*/
publicHost?: pulumi.Input<string>;
/**
* The ID of the region that the managed database read replica is to be created in. [See List Regions](https://www.vultr.com/api/#operation/list-regions)
*/
region: pulumi.Input<string>;
/**
* The tag to assign to the managed database read replica.
*/
tag?: pulumi.Input<string>;
/**
* A list of allowed IP addresses for the managed database read replica.
*/
trustedIps?: pulumi.Input<pulumi.Input<string>[]>;
}