We recommend using Azure Native.
Azure v6.10.0 published on Tuesday, Nov 19, 2024 by Pulumi
azure.devtest.getLab
Explore with Pulumi AI
Use this data source to access information about an existing Dev Test Lab.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = azure.devtest.getLab({
name: "example-lab",
resourceGroupName: "example-resources",
});
export const uniqueIdentifier = example.then(example => example.uniqueIdentifier);
import pulumi
import pulumi_azure as azure
example = azure.devtest.get_lab(name="example-lab",
resource_group_name="example-resources")
pulumi.export("uniqueIdentifier", example.unique_identifier)
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/devtest"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := devtest.LookupLab(ctx, &devtest.LookupLabArgs{
Name: "example-lab",
ResourceGroupName: "example-resources",
}, nil)
if err != nil {
return err
}
ctx.Export("uniqueIdentifier", example.UniqueIdentifier)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example = Azure.DevTest.GetLab.Invoke(new()
{
Name = "example-lab",
ResourceGroupName = "example-resources",
});
return new Dictionary<string, object?>
{
["uniqueIdentifier"] = example.Apply(getLabResult => getLabResult.UniqueIdentifier),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.devtest.DevtestFunctions;
import com.pulumi.azure.devtest.inputs.GetLabArgs;
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 example = DevtestFunctions.getLab(GetLabArgs.builder()
.name("example-lab")
.resourceGroupName("example-resources")
.build());
ctx.export("uniqueIdentifier", example.applyValue(getLabResult -> getLabResult.uniqueIdentifier()));
}
}
variables:
example:
fn::invoke:
Function: azure:devtest:getLab
Arguments:
name: example-lab
resourceGroupName: example-resources
outputs:
uniqueIdentifier: ${example.uniqueIdentifier}
Using getLab
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 getLab(args: GetLabArgs, opts?: InvokeOptions): Promise<GetLabResult>
function getLabOutput(args: GetLabOutputArgs, opts?: InvokeOptions): Output<GetLabResult>
def get_lab(name: Optional[str] = None,
resource_group_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetLabResult
def get_lab_output(name: Optional[pulumi.Input[str]] = None,
resource_group_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetLabResult]
func LookupLab(ctx *Context, args *LookupLabArgs, opts ...InvokeOption) (*LookupLabResult, error)
func LookupLabOutput(ctx *Context, args *LookupLabOutputArgs, opts ...InvokeOption) LookupLabResultOutput
> Note: This function is named LookupLab
in the Go SDK.
public static class GetLab
{
public static Task<GetLabResult> InvokeAsync(GetLabArgs args, InvokeOptions? opts = null)
public static Output<GetLabResult> Invoke(GetLabInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetLabResult> getLab(GetLabArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: azure:devtest/getLab:getLab
arguments:
# arguments dictionary
The following arguments are supported:
- Name string
- The name of the Dev Test Lab.
- Resource
Group stringName - The Name of the Resource Group where the Dev Test Lab exists.
- Name string
- The name of the Dev Test Lab.
- Resource
Group stringName - The Name of the Resource Group where the Dev Test Lab exists.
- name String
- The name of the Dev Test Lab.
- resource
Group StringName - The Name of the Resource Group where the Dev Test Lab exists.
- name string
- The name of the Dev Test Lab.
- resource
Group stringName - The Name of the Resource Group where the Dev Test Lab exists.
- name str
- The name of the Dev Test Lab.
- resource_
group_ strname - The Name of the Resource Group where the Dev Test Lab exists.
- name String
- The name of the Dev Test Lab.
- resource
Group StringName - The Name of the Resource Group where the Dev Test Lab exists.
getLab Result
The following output properties are available:
- Artifacts
Storage stringAccount Id - The ID of the Storage Account used for Artifact Storage.
- string
- The ID of the Default Premium Storage Account for this Dev Test Lab.
- Default
Storage stringAccount Id - The ID of the Default Storage Account for this Dev Test Lab.
- Id string
- The provider-assigned unique ID for this managed resource.
- Key
Vault stringId - The ID of the Key used for this Dev Test Lab.
- Location string
- The Azure location where the Dev Test Lab exists.
- Name string
- string
- The ID of the Storage Account used for Storage of Premium Data Disk.
- Resource
Group stringName - Storage
Type string - The type of storage used by the Dev Test Lab.
- Dictionary<string, string>
- A mapping of tags to assign to the resource.
- Unique
Identifier string - The unique immutable identifier of the Dev Test Lab.
- Artifacts
Storage stringAccount Id - The ID of the Storage Account used for Artifact Storage.
- string
- The ID of the Default Premium Storage Account for this Dev Test Lab.
- Default
Storage stringAccount Id - The ID of the Default Storage Account for this Dev Test Lab.
- Id string
- The provider-assigned unique ID for this managed resource.
- Key
Vault stringId - The ID of the Key used for this Dev Test Lab.
- Location string
- The Azure location where the Dev Test Lab exists.
- Name string
- string
- The ID of the Storage Account used for Storage of Premium Data Disk.
- Resource
Group stringName - Storage
Type string - The type of storage used by the Dev Test Lab.
- map[string]string
- A mapping of tags to assign to the resource.
- Unique
Identifier string - The unique immutable identifier of the Dev Test Lab.
- artifacts
Storage StringAccount Id - The ID of the Storage Account used for Artifact Storage.
- String
- The ID of the Default Premium Storage Account for this Dev Test Lab.
- default
Storage StringAccount Id - The ID of the Default Storage Account for this Dev Test Lab.
- id String
- The provider-assigned unique ID for this managed resource.
- key
Vault StringId - The ID of the Key used for this Dev Test Lab.
- location String
- The Azure location where the Dev Test Lab exists.
- name String
- String
- The ID of the Storage Account used for Storage of Premium Data Disk.
- resource
Group StringName - storage
Type String - The type of storage used by the Dev Test Lab.
- Map<String,String>
- A mapping of tags to assign to the resource.
- unique
Identifier String - The unique immutable identifier of the Dev Test Lab.
- artifacts
Storage stringAccount Id - The ID of the Storage Account used for Artifact Storage.
- string
- The ID of the Default Premium Storage Account for this Dev Test Lab.
- default
Storage stringAccount Id - The ID of the Default Storage Account for this Dev Test Lab.
- id string
- The provider-assigned unique ID for this managed resource.
- key
Vault stringId - The ID of the Key used for this Dev Test Lab.
- location string
- The Azure location where the Dev Test Lab exists.
- name string
- string
- The ID of the Storage Account used for Storage of Premium Data Disk.
- resource
Group stringName - storage
Type string - The type of storage used by the Dev Test Lab.
- {[key: string]: string}
- A mapping of tags to assign to the resource.
- unique
Identifier string - The unique immutable identifier of the Dev Test Lab.
- artifacts_
storage_ straccount_ id - The ID of the Storage Account used for Artifact Storage.
- str
- The ID of the Default Premium Storage Account for this Dev Test Lab.
- default_
storage_ straccount_ id - The ID of the Default Storage Account for this Dev Test Lab.
- id str
- The provider-assigned unique ID for this managed resource.
- key_
vault_ strid - The ID of the Key used for this Dev Test Lab.
- location str
- The Azure location where the Dev Test Lab exists.
- name str
- str
- The ID of the Storage Account used for Storage of Premium Data Disk.
- resource_
group_ strname - storage_
type str - The type of storage used by the Dev Test Lab.
- Mapping[str, str]
- A mapping of tags to assign to the resource.
- unique_
identifier str - The unique immutable identifier of the Dev Test Lab.
- artifacts
Storage StringAccount Id - The ID of the Storage Account used for Artifact Storage.
- String
- The ID of the Default Premium Storage Account for this Dev Test Lab.
- default
Storage StringAccount Id - The ID of the Default Storage Account for this Dev Test Lab.
- id String
- The provider-assigned unique ID for this managed resource.
- key
Vault StringId - The ID of the Key used for this Dev Test Lab.
- location String
- The Azure location where the Dev Test Lab exists.
- name String
- String
- The ID of the Storage Account used for Storage of Premium Data Disk.
- resource
Group StringName - storage
Type String - The type of storage used by the Dev Test Lab.
- Map<String>
- A mapping of tags to assign to the resource.
- unique
Identifier String - The unique immutable identifier of the Dev Test Lab.
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurerm
Terraform Provider.