vkcs 0.9.3 published on Tuesday, Apr 15, 2025 by vk-cs
vkcs.getDbDatastores
Explore with Pulumi AI
Use this data source to get a list of datastores from VKCS.
New since v0.2.0.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as vkcs from "@pulumi/vkcs";
const datastores = vkcs.getDbDatastores({});
export const availableDatastores = datastores.then(datastores => datastores.datastores);
import pulumi
import pulumi_vkcs as vkcs
datastores = vkcs.get_db_datastores()
pulumi.export("availableDatastores", datastores.datastores)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/vkcs/vkcs"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
datastores, err := vkcs.GetDbDatastores(ctx, &vkcs.GetDbDatastoresArgs{}, nil)
if err != nil {
return err
}
ctx.Export("availableDatastores", datastores.Datastores)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vkcs = Pulumi.Vkcs;
return await Deployment.RunAsync(() =>
{
var datastores = Vkcs.GetDbDatastores.Invoke();
return new Dictionary<string, object?>
{
["availableDatastores"] = datastores.Apply(getDbDatastoresResult => getDbDatastoresResult.Datastores),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vkcs.VkcsFunctions;
import com.pulumi.vkcs.inputs.GetDbDatastoresArgs;
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) {
final var datastores = VkcsFunctions.getDbDatastores();
ctx.export("availableDatastores", datastores.applyValue(getDbDatastoresResult -> getDbDatastoresResult.datastores()));
}
}
variables:
datastores:
fn::invoke:
function: vkcs:getDbDatastores
arguments: {}
outputs:
availableDatastores: ${datastores.datastores}
Using getDbDatastores
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getDbDatastores(args: GetDbDatastoresArgs, opts?: InvokeOptions): Promise<GetDbDatastoresResult>
function getDbDatastoresOutput(args: GetDbDatastoresOutputArgs, opts?: InvokeOptions): Output<GetDbDatastoresResult>
def get_db_datastores(id: Optional[str] = None,
region: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetDbDatastoresResult
def get_db_datastores_output(id: Optional[pulumi.Input[str]] = None,
region: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetDbDatastoresResult]
func GetDbDatastores(ctx *Context, args *GetDbDatastoresArgs, opts ...InvokeOption) (*GetDbDatastoresResult, error)
func GetDbDatastoresOutput(ctx *Context, args *GetDbDatastoresOutputArgs, opts ...InvokeOption) GetDbDatastoresResultOutput
> Note: This function is named GetDbDatastores
in the Go SDK.
public static class GetDbDatastores
{
public static Task<GetDbDatastoresResult> InvokeAsync(GetDbDatastoresArgs args, InvokeOptions? opts = null)
public static Output<GetDbDatastoresResult> Invoke(GetDbDatastoresInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetDbDatastoresResult> getDbDatastores(GetDbDatastoresArgs args, InvokeOptions options)
public static Output<GetDbDatastoresResult> getDbDatastores(GetDbDatastoresArgs args, InvokeOptions options)
fn::invoke:
function: vkcs:index/getDbDatastores:getDbDatastores
arguments:
# arguments dictionary
The following arguments are supported:
getDbDatastores Result
The following output properties are available:
- Datastores
List<Get
Db Datastores Datastore> - list → List of datastores within VKCS.
- Id string
- string → ID of the resource.
- Region string
- Datastores
[]Get
Db Datastores Datastore - list → List of datastores within VKCS.
- Id string
- string → ID of the resource.
- Region string
- datastores
List<Get
Db Datastores Datastore> - list → List of datastores within VKCS.
- id String
- string → ID of the resource.
- region String
- datastores
Get
Db Datastores Datastore[] - list → List of datastores within VKCS.
- id string
- string → ID of the resource.
- region string
- datastores
Sequence[Get
Db Datastores Datastore] - list → List of datastores within VKCS.
- id str
- string → ID of the resource.
- region str
- datastores List<Property Map>
- list → List of datastores within VKCS.
- id String
- string → ID of the resource.
- region String
Supporting Types
GetDbDatastoresDatastore
Package Details
- Repository
- vkcs vk-cs/terraform-provider-vkcs
- License
- Notes
- This Pulumi package is based on the
vkcs
Terraform Provider.