UNPKG

@pulumiverse/scaleway

Version:

A Pulumi package for creating and managing Scaleway cloud resources.

100 lines (99 loc) 3.21 kB
import * as pulumi from "@pulumi/pulumi"; /** * Gets information about the privileges in a database. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as scaleway from "@pulumi/scaleway"; * * // Get the database privilege for the user "my-user" on the database "my-database" hosted on instance id 11111111-1111-1111-1111-111111111111 and on the default region. e.g: fr-par * const main = scaleway.databases.getPrivilege({ * instanceId: "11111111-1111-111111111111", * userName: "my-user", * databaseName: "my-database", * }); * ``` */ /** @deprecated scaleway.index/getdatabaseprivilege.getDatabasePrivilege has been deprecated in favor of scaleway.databases/getprivilege.getPrivilege */ export declare function getDatabasePrivilege(args: GetDatabasePrivilegeArgs, opts?: pulumi.InvokeOptions): Promise<GetDatabasePrivilegeResult>; /** * A collection of arguments for invoking getDatabasePrivilege. */ export interface GetDatabasePrivilegeArgs { /** * The database name. */ databaseName: string; /** * The Database Instance ID. */ instanceId: string; /** * `region`) The region in which the resource exists. */ region?: string; /** * The user name. */ userName: string; } /** * A collection of values returned by getDatabasePrivilege. */ export interface GetDatabasePrivilegeResult { readonly databaseName: string; /** * The provider-assigned unique ID for this managed resource. */ readonly id: string; readonly instanceId: string; /** * The permission for this user on the database. Possible values are `readonly`, `readwrite`, `all` * , `custom` and `none`. */ readonly permission: string; readonly region?: string; readonly userName: string; } /** * Gets information about the privileges in a database. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as scaleway from "@pulumi/scaleway"; * * // Get the database privilege for the user "my-user" on the database "my-database" hosted on instance id 11111111-1111-1111-1111-111111111111 and on the default region. e.g: fr-par * const main = scaleway.databases.getPrivilege({ * instanceId: "11111111-1111-111111111111", * userName: "my-user", * databaseName: "my-database", * }); * ``` */ /** @deprecated scaleway.index/getdatabaseprivilege.getDatabasePrivilege has been deprecated in favor of scaleway.databases/getprivilege.getPrivilege */ export declare function getDatabasePrivilegeOutput(args: GetDatabasePrivilegeOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetDatabasePrivilegeResult>; /** * A collection of arguments for invoking getDatabasePrivilege. */ export interface GetDatabasePrivilegeOutputArgs { /** * The database name. */ databaseName: pulumi.Input<string>; /** * The Database Instance ID. */ instanceId: pulumi.Input<string>; /** * `region`) The region in which the resource exists. */ region?: pulumi.Input<string>; /** * The user name. */ userName: pulumi.Input<string>; }