1. Packages
  2. Google Cloud (GCP) Classic
  3. API Docs
  4. vmwareengine
  5. getDatastore
Google Cloud v9.11.0 published on Tuesday, Feb 3, 2026 by Pulumi
gcp logo
Google Cloud v9.11.0 published on Tuesday, Feb 3, 2026 by Pulumi

    Use this data source to get details about a datastore resource.

    To get more information about datastore, see:

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const testDs = gcp.vmwareengine.getDatastore({
        name: "example-ds",
        location: "us-west2",
    });
    
    import pulumi
    import pulumi_gcp as gcp
    
    test_ds = gcp.vmwareengine.get_datastore(name="example-ds",
        location="us-west2")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/vmwareengine"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := vmwareengine.LookupDatastore(ctx, &vmwareengine.LookupDatastoreArgs{
    			Name:     "example-ds",
    			Location: "us-west2",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var testDs = Gcp.VMwareEngine.GetDatastore.Invoke(new()
        {
            Name = "example-ds",
            Location = "us-west2",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.vmwareengine.VmwareengineFunctions;
    import com.pulumi.gcp.vmwareengine.inputs.GetDatastoreArgs;
    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 testDs = VmwareengineFunctions.getDatastore(GetDatastoreArgs.builder()
                .name("example-ds")
                .location("us-west2")
                .build());
    
        }
    }
    
    variables:
      testDs:
        fn::invoke:
          function: gcp:vmwareengine:getDatastore
          arguments:
            name: example-ds
            location: us-west2
    

    Using getDatastore

    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 getDatastore(args: GetDatastoreArgs, opts?: InvokeOptions): Promise<GetDatastoreResult>
    function getDatastoreOutput(args: GetDatastoreOutputArgs, opts?: InvokeOptions): Output<GetDatastoreResult>
    def get_datastore(location: Optional[str] = None,
                      name: Optional[str] = None,
                      project: Optional[str] = None,
                      opts: Optional[InvokeOptions] = None) -> GetDatastoreResult
    def get_datastore_output(location: Optional[pulumi.Input[str]] = None,
                      name: Optional[pulumi.Input[str]] = None,
                      project: Optional[pulumi.Input[str]] = None,
                      opts: Optional[InvokeOptions] = None) -> Output[GetDatastoreResult]
    func LookupDatastore(ctx *Context, args *LookupDatastoreArgs, opts ...InvokeOption) (*LookupDatastoreResult, error)
    func LookupDatastoreOutput(ctx *Context, args *LookupDatastoreOutputArgs, opts ...InvokeOption) LookupDatastoreResultOutput

    > Note: This function is named LookupDatastore in the Go SDK.

    public static class GetDatastore 
    {
        public static Task<GetDatastoreResult> InvokeAsync(GetDatastoreArgs args, InvokeOptions? opts = null)
        public static Output<GetDatastoreResult> Invoke(GetDatastoreInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetDatastoreResult> getDatastore(GetDatastoreArgs args, InvokeOptions options)
    public static Output<GetDatastoreResult> getDatastore(GetDatastoreArgs args, InvokeOptions options)
    
    fn::invoke:
      function: gcp:vmwareengine/getDatastore:getDatastore
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Location string
    either regional or zonal location of the resource.
    Name string
    Name of the resource.
    Project string
    Location string
    either regional or zonal location of the resource.
    Name string
    Name of the resource.
    Project string
    location String
    either regional or zonal location of the resource.
    name String
    Name of the resource.
    project String
    location string
    either regional or zonal location of the resource.
    name string
    Name of the resource.
    project string
    location str
    either regional or zonal location of the resource.
    name str
    Name of the resource.
    project str
    location String
    either regional or zonal location of the resource.
    name String
    Name of the resource.
    project String

    getDatastore Result

    The following output properties are available:

    Clusters List<string>
    CreateTime string
    Description string
    Id string
    The provider-assigned unique ID for this managed resource.
    Location string
    Name string
    NfsDatastores List<GetDatastoreNfsDatastore>
    State string
    Uid string
    UpdateTime string
    Project string
    Clusters []string
    CreateTime string
    Description string
    Id string
    The provider-assigned unique ID for this managed resource.
    Location string
    Name string
    NfsDatastores []GetDatastoreNfsDatastore
    State string
    Uid string
    UpdateTime string
    Project string
    clusters List<String>
    createTime String
    description String
    id String
    The provider-assigned unique ID for this managed resource.
    location String
    name String
    nfsDatastores List<GetDatastoreNfsDatastore>
    state String
    uid String
    updateTime String
    project String
    clusters string[]
    createTime string
    description string
    id string
    The provider-assigned unique ID for this managed resource.
    location string
    name string
    nfsDatastores GetDatastoreNfsDatastore[]
    state string
    uid string
    updateTime string
    project string
    clusters Sequence[str]
    create_time str
    description str
    id str
    The provider-assigned unique ID for this managed resource.
    location str
    name str
    nfs_datastores Sequence[GetDatastoreNfsDatastore]
    state str
    uid str
    update_time str
    project str
    clusters List<String>
    createTime String
    description String
    id String
    The provider-assigned unique ID for this managed resource.
    location String
    name String
    nfsDatastores List<Property Map>
    state String
    uid String
    updateTime String
    project String

    Supporting Types

    GetDatastoreNfsDatastore

    googleFileServices List<Property Map>
    Google service file service configuration
    thirdPartyFileServices List<Property Map>
    Third party file service configuration

    GetDatastoreNfsDatastoreGoogleFileService

    FilestoreInstance string
    Google filestore instance resource name e.g. projects/my-project/locations/me-west1-b/instances/my-instance
    NetappVolume string
    Google netapp volume resource name e.g. projects/my-project/locations/me-west1-b/volumes/my-volume
    FilestoreInstance string
    Google filestore instance resource name e.g. projects/my-project/locations/me-west1-b/instances/my-instance
    NetappVolume string
    Google netapp volume resource name e.g. projects/my-project/locations/me-west1-b/volumes/my-volume
    filestoreInstance String
    Google filestore instance resource name e.g. projects/my-project/locations/me-west1-b/instances/my-instance
    netappVolume String
    Google netapp volume resource name e.g. projects/my-project/locations/me-west1-b/volumes/my-volume
    filestoreInstance string
    Google filestore instance resource name e.g. projects/my-project/locations/me-west1-b/instances/my-instance
    netappVolume string
    Google netapp volume resource name e.g. projects/my-project/locations/me-west1-b/volumes/my-volume
    filestore_instance str
    Google filestore instance resource name e.g. projects/my-project/locations/me-west1-b/instances/my-instance
    netapp_volume str
    Google netapp volume resource name e.g. projects/my-project/locations/me-west1-b/volumes/my-volume
    filestoreInstance String
    Google filestore instance resource name e.g. projects/my-project/locations/me-west1-b/instances/my-instance
    netappVolume String
    Google netapp volume resource name e.g. projects/my-project/locations/me-west1-b/volumes/my-volume

    GetDatastoreNfsDatastoreThirdPartyFileService

    FileShare string
    Required Mount Folder name
    Network string
    Required to identify vpc peering used for NFS access network name of NFS's vpc e.g. projects/project-id/global/networks/my-network_id
    Servers List<string>
    Server IP addresses of the NFS file service. NFS v3, provide a single IP address or DNS name. Multiple servers can be supported in future when NFS 4.1 protocol support is enabled.
    FileShare string
    Required Mount Folder name
    Network string
    Required to identify vpc peering used for NFS access network name of NFS's vpc e.g. projects/project-id/global/networks/my-network_id
    Servers []string
    Server IP addresses of the NFS file service. NFS v3, provide a single IP address or DNS name. Multiple servers can be supported in future when NFS 4.1 protocol support is enabled.
    fileShare String
    Required Mount Folder name
    network String
    Required to identify vpc peering used for NFS access network name of NFS's vpc e.g. projects/project-id/global/networks/my-network_id
    servers List<String>
    Server IP addresses of the NFS file service. NFS v3, provide a single IP address or DNS name. Multiple servers can be supported in future when NFS 4.1 protocol support is enabled.
    fileShare string
    Required Mount Folder name
    network string
    Required to identify vpc peering used for NFS access network name of NFS's vpc e.g. projects/project-id/global/networks/my-network_id
    servers string[]
    Server IP addresses of the NFS file service. NFS v3, provide a single IP address or DNS name. Multiple servers can be supported in future when NFS 4.1 protocol support is enabled.
    file_share str
    Required Mount Folder name
    network str
    Required to identify vpc peering used for NFS access network name of NFS's vpc e.g. projects/project-id/global/networks/my-network_id
    servers Sequence[str]
    Server IP addresses of the NFS file service. NFS v3, provide a single IP address or DNS name. Multiple servers can be supported in future when NFS 4.1 protocol support is enabled.
    fileShare String
    Required Mount Folder name
    network String
    Required to identify vpc peering used for NFS access network name of NFS's vpc e.g. projects/project-id/global/networks/my-network_id
    servers List<String>
    Server IP addresses of the NFS file service. NFS v3, provide a single IP address or DNS name. Multiple servers can be supported in future when NFS 4.1 protocol support is enabled.

    Package Details

    Repository
    Google Cloud (GCP) Classic pulumi/pulumi-gcp
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the google-beta Terraform Provider.
    gcp logo
    Google Cloud v9.11.0 published on Tuesday, Feb 3, 2026 by Pulumi
      Meet Neo: Your AI Platform Teammate