LabPlan

class LabPlan : KotlinCustomResource

Lab Plans act as a permission container for creating labs via labs.azure.com. Additionally, they can provide a set of default configurations that will apply at the time of creating a lab, but these defaults can still be overwritten. Uses Azure REST API version 2022-08-01. In version 1.x of the Azure Native provider, it used API version 2021-10-01-preview. Other available API versions: 2023-06-07.

Example Usage

putLabPlan

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var labPlan = new AzureNative.LabServices.LabPlan("labPlan", new()
{
DefaultAutoShutdownProfile = new AzureNative.LabServices.Inputs.AutoShutdownProfileArgs
{
DisconnectDelay = "PT5M",
IdleDelay = "PT5M",
NoConnectDelay = "PT5M",
ShutdownOnDisconnect = AzureNative.LabServices.EnableState.Enabled,
ShutdownOnIdle = AzureNative.LabServices.ShutdownOnIdleMode.UserAbsence,
ShutdownWhenNotConnected = AzureNative.LabServices.EnableState.Enabled,
},
DefaultConnectionProfile = new AzureNative.LabServices.Inputs.ConnectionProfileArgs
{
ClientRdpAccess = AzureNative.LabServices.ConnectionType.Public,
ClientSshAccess = AzureNative.LabServices.ConnectionType.Public,
WebRdpAccess = AzureNative.LabServices.ConnectionType.None,
WebSshAccess = AzureNative.LabServices.ConnectionType.None,
},
DefaultNetworkProfile = new AzureNative.LabServices.Inputs.LabPlanNetworkProfileArgs
{
SubnetId = "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/default",
},
LabPlanName = "testlabplan",
Location = "westus",
ResourceGroupName = "testrg123",
SharedGalleryId = "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Compute/galleries/testsig",
SupportInfo = new AzureNative.LabServices.Inputs.SupportInfoArgs
{
Email = "help@contoso.com",
Instructions = "Contact support for help.",
Phone = "+1-202-555-0123",
Url = "help.contoso.com",
},
});
});
package main
import (
labservices "github.com/pulumi/pulumi-azure-native-sdk/labservices/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := labservices.NewLabPlan(ctx, "labPlan", &labservices.LabPlanArgs{
DefaultAutoShutdownProfile: &labservices.AutoShutdownProfileArgs{
DisconnectDelay: pulumi.String("PT5M"),
IdleDelay: pulumi.String("PT5M"),
NoConnectDelay: pulumi.String("PT5M"),
ShutdownOnDisconnect: labservices.EnableStateEnabled,
ShutdownOnIdle: labservices.ShutdownOnIdleModeUserAbsence,
ShutdownWhenNotConnected: labservices.EnableStateEnabled,
},
DefaultConnectionProfile: &labservices.ConnectionProfileArgs{
ClientRdpAccess: labservices.ConnectionTypePublic,
ClientSshAccess: labservices.ConnectionTypePublic,
WebRdpAccess: labservices.ConnectionTypeNone,
WebSshAccess: labservices.ConnectionTypeNone,
},
DefaultNetworkProfile: &labservices.LabPlanNetworkProfileArgs{
SubnetId: pulumi.String("/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/default"),
},
LabPlanName: pulumi.String("testlabplan"),
Location: pulumi.String("westus"),
ResourceGroupName: pulumi.String("testrg123"),
SharedGalleryId: pulumi.String("/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Compute/galleries/testsig"),
SupportInfo: &labservices.SupportInfoArgs{
Email: pulumi.String("help@contoso.com"),
Instructions: pulumi.String("Contact support for help."),
Phone: pulumi.String("+1-202-555-0123"),
Url: pulumi.String("help.contoso.com"),
},
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.labservices.LabPlan;
import com.pulumi.azurenative.labservices.LabPlanArgs;
import com.pulumi.azurenative.labservices.inputs.AutoShutdownProfileArgs;
import com.pulumi.azurenative.labservices.inputs.ConnectionProfileArgs;
import com.pulumi.azurenative.labservices.inputs.LabPlanNetworkProfileArgs;
import com.pulumi.azurenative.labservices.inputs.SupportInfoArgs;
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) {
var labPlan = new LabPlan("labPlan", LabPlanArgs.builder()
.defaultAutoShutdownProfile(AutoShutdownProfileArgs.builder()
.disconnectDelay("PT5M")
.idleDelay("PT5M")
.noConnectDelay("PT5M")
.shutdownOnDisconnect("Enabled")
.shutdownOnIdle("UserAbsence")
.shutdownWhenNotConnected("Enabled")
.build())
.defaultConnectionProfile(ConnectionProfileArgs.builder()
.clientRdpAccess("Public")
.clientSshAccess("Public")
.webRdpAccess("None")
.webSshAccess("None")
.build())
.defaultNetworkProfile(LabPlanNetworkProfileArgs.builder()
.subnetId("/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/default")
.build())
.labPlanName("testlabplan")
.location("westus")
.resourceGroupName("testrg123")
.sharedGalleryId("/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Compute/galleries/testsig")
.supportInfo(SupportInfoArgs.builder()
.email("help@contoso.com")
.instructions("Contact support for help.")
.phone("+1-202-555-0123")
.url("help.contoso.com")
.build())
.build());
}
}

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:labservices:LabPlan testlabplan /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.LabServices/labPlans/{labPlanName}

Properties

Link copied to clipboard
val allowedRegions: Output<List<String>>?

The allowed regions for the lab creator to use when creating labs using this lab plan.

Link copied to clipboard

The default lab shutdown profile. This can be changed on a lab resource and only provides a default profile.

Link copied to clipboard

The default lab connection profile. This can be changed on a lab resource and only provides a default profile.

Link copied to clipboard

The lab plan network profile. To enforce lab network policies they must be defined here and cannot be changed when there are existing labs associated with this lab plan.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard

Managed Identity Information

Link copied to clipboard

Base Url of the lms instance this lab plan can link lab rosters against.

Link copied to clipboard
val location: Output<String>

The geo-location where the resource lives

Link copied to clipboard
val name: Output<String>

The name of the resource

Link copied to clipboard

Current provisioning state of the lab plan.

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val sharedGalleryId: Output<String>?

Resource ID of the Shared Image Gallery attached to this lab plan. When saving a lab template virtual machine image it will be persisted in this gallery. Shared images from the gallery can be made available to use when creating new labs.

Link copied to clipboard

Support contact information and instructions for users of the lab plan. This information is displayed to lab owners and virtual machine users for all labs in the lab plan.

Link copied to clipboard

Metadata pertaining to creation and last modification of the lab plan.

Link copied to clipboard
val tags: Output<Map<String, String>>?

Resource tags.

Link copied to clipboard
val type: Output<String>

The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"

Link copied to clipboard
val urn: Output<String>