import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as ovh from "@ovhcloud/pulumi-ovh"; * * const myaccount = ovh.Me.getMe({}); * const mycart = myaccount.then(myaccount => ovh.Order.getCart({ * ovhSubsidiary: myaccount.ovhSubsidiary, * })); * const database = mycart.then(mycart => ovh.Order.getCartProductPlan({ * cartId: mycart.id, * priceCapacity: "renew", * product: "privateSQL", * planCode: "private-sql-512-instance", * })); * const databasePrivateDatabase = new ovh.hosting.PrivateDatabase("database", { * ovhSubsidiary: mycart.then(mycart => mycart.ovhSubsidiary), * displayName: "Postgresql-12", * plan: { * duration: database.then(database => database.prices?.[3]?.duration), * planCode: database.then(database => database.planCode), * pricingMode: database.then(database => database.selectedPrices?.[0]?.pricingMode), * configurations: [ * { * label: "dc", * value: "gra3", * }, * { * label: "engine", * value: "postgresql_12", * }, * ], * }, * }); * export const privatedatabaseServiceName = databasePrivateDatabase.serviceName; * ``` * * ## Import * * OVHcloud Webhosting database can be imported using the `service_name`. Using the following configuration: * * terraform * * import { * * to = ovh_hosting_privatedatabase.database * * id = "" * * } * * You can then run: * * bash * * $ pulumi preview -generate-config-out=database.tf * * $ pulumi up * * The file `database.tf` will then contain the imported resource's configuration, that can be copied next to the `import` block above. See https://developer.hashicorp.com/terraform/language/import/generating-configuration for more details. */ export declare class PrivateDatabase extends pulumi.CustomResource { /** * Get an existing PrivateDatabase 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, state?: PrivateDatabaseState, opts?: pulumi.CustomResourceOptions): PrivateDatabase; /** * Returns true if the given object is an instance of PrivateDatabase. 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 PrivateDatabase; /** * URN of the private database, used when writing IAM policies */ readonly DatabaseURN: pulumi.Output; /** * Advanced configuration key / value. */ readonly advancedConfiguration: pulumi.Output<{ [key: string]: string; }>; /** * Number of CPU on your private database */ readonly cpu: pulumi.Output; /** * Datacenter where this private database is located */ readonly datacenter: pulumi.Output; /** * Name displayed in customer panel for your private database */ readonly displayName: pulumi.Output; /** * Private database hostname */ readonly hostname: pulumi.Output; /** * Private database FTP hostname */ readonly hostnameFtp: pulumi.Output; /** * Infrastructure where service was stored */ readonly infrastructure: pulumi.Output; /** * Type of the private database offer */ readonly offer: pulumi.Output; /** * Details about your Order */ readonly orders: pulumi.Output; /** * OVHcloud Subsidiary. Country of OVHcloud legal entity you'll be billed by. List of supported subsidiaries available on API at [/1.0/me.json under `models.nichandle.OvhSubsidiaryEnum`](https://eu.api.ovh.com/1.0/me.json) */ readonly ovhSubsidiary: pulumi.Output; /** * Ovh payment mode * * @deprecated This field is not anymore used since the API has been deprecated in favor of /payment/mean. Now, the default payment mean is used. */ readonly paymentMean: pulumi.Output; /** * Product Plan to order */ readonly plan: pulumi.Output; /** * Product Plan to order */ readonly planOptions: pulumi.Output; /** * Private database service port */ readonly port: pulumi.Output; /** * Private database FTP port */ readonly portFtp: pulumi.Output; /** * Space allowed (in MB) on your private database */ readonly quotaSize: pulumi.Output; /** * Sapce used (in MB) on your private database */ readonly quotaUsed: pulumi.Output; /** * Amount of ram (in MB) on your private database */ readonly ram: pulumi.Output; /** * Private database server name */ readonly server: pulumi.Output; /** * Service name */ readonly serviceName: pulumi.Output; /** * Private database state */ readonly state: pulumi.Output; /** * Private database type */ readonly type: pulumi.Output; /** * Private database available versions */ readonly version: pulumi.Output; /** * Private database version label */ readonly versionLabel: pulumi.Output; /** * Private database version number */ readonly versionNumber: pulumi.Output; /** * Create a PrivateDatabase 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?: PrivateDatabaseArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering PrivateDatabase resources. */ export interface PrivateDatabaseState { /** * URN of the private database, used when writing IAM policies */ DatabaseURN?: pulumi.Input; /** * Advanced configuration key / value. */ advancedConfiguration?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * Number of CPU on your private database */ cpu?: pulumi.Input; /** * Datacenter where this private database is located */ datacenter?: pulumi.Input; /** * Name displayed in customer panel for your private database */ displayName?: pulumi.Input; /** * Private database hostname */ hostname?: pulumi.Input; /** * Private database FTP hostname */ hostnameFtp?: pulumi.Input; /** * Infrastructure where service was stored */ infrastructure?: pulumi.Input; /** * Type of the private database offer */ offer?: pulumi.Input; /** * Details about your Order */ orders?: pulumi.Input[]>; /** * OVHcloud Subsidiary. Country of OVHcloud legal entity you'll be billed by. List of supported subsidiaries available on API at [/1.0/me.json under `models.nichandle.OvhSubsidiaryEnum`](https://eu.api.ovh.com/1.0/me.json) */ ovhSubsidiary?: pulumi.Input; /** * Ovh payment mode * * @deprecated This field is not anymore used since the API has been deprecated in favor of /payment/mean. Now, the default payment mean is used. */ paymentMean?: pulumi.Input; /** * Product Plan to order */ plan?: pulumi.Input; /** * Product Plan to order */ planOptions?: pulumi.Input[]>; /** * Private database service port */ port?: pulumi.Input; /** * Private database FTP port */ portFtp?: pulumi.Input; /** * Space allowed (in MB) on your private database */ quotaSize?: pulumi.Input; /** * Sapce used (in MB) on your private database */ quotaUsed?: pulumi.Input; /** * Amount of ram (in MB) on your private database */ ram?: pulumi.Input; /** * Private database server name */ server?: pulumi.Input; /** * Service name */ serviceName?: pulumi.Input; /** * Private database state */ state?: pulumi.Input; /** * Private database type */ type?: pulumi.Input; /** * Private database available versions */ version?: pulumi.Input; /** * Private database version label */ versionLabel?: pulumi.Input; /** * Private database version number */ versionNumber?: pulumi.Input; } /** * The set of arguments for constructing a PrivateDatabase resource. */ export interface PrivateDatabaseArgs { /** * Advanced configuration key / value. */ advancedConfiguration?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * Name displayed in customer panel for your private database */ displayName?: pulumi.Input; /** * Details about your Order */ orders?: pulumi.Input[]>; /** * OVHcloud Subsidiary. Country of OVHcloud legal entity you'll be billed by. List of supported subsidiaries available on API at [/1.0/me.json under `models.nichandle.OvhSubsidiaryEnum`](https://eu.api.ovh.com/1.0/me.json) */ ovhSubsidiary?: pulumi.Input; /** * Ovh payment mode * * @deprecated This field is not anymore used since the API has been deprecated in favor of /payment/mean. Now, the default payment mean is used. */ paymentMean?: pulumi.Input; /** * Product Plan to order */ plan?: pulumi.Input; /** * Product Plan to order */ planOptions?: pulumi.Input[]>; /** * Service name */ serviceName?: pulumi.Input; }