azurerm_lab_service_user

Manages a Lab Service User.

Example Usage

resource "azurerm_resource_group" "example" {
  name     = "example-resources"
  location = "West Europe"
}

resource "azurerm_lab_service_lab" "example" {
  name                = "example-lab"
  resource_group_name = azurerm_resource_group.example.name
  location            = azurerm_resource_group.example.location
  title               = "Test Title"

  security {
    open_access_enabled = false
  }

  virtual_machine {
    admin_user {
      username = "testadmin"
      password = "Password1234!"
    }

    image_reference {
      publisher = "Canonical"
      offer     = "0001-com-ubuntu-server-jammy"
      sku       = "22_04-lts"
      version   = "latest"
    }

    sku {
      name     = "Classic_Fsv2_2_4GB_128_S_SSD"
      capacity = 1
    }
  }
}

resource "azurerm_lab_service_user" "example" {
  name   = "example-labuser"
  lab_id = azurerm_lab_service_lab.example.id
  email  = "terraform-acctest@hashicorp.com"
}

Arguments Reference

The following arguments are supported:

Attributes Reference

In addition to the Arguments listed above - the following Attributes are exported:

Timeouts

The timeouts block allows you to specify timeouts for certain actions:

Import

Lab Service Users can be imported using the resource id, e.g.

terraform import azurerm_lab_service_user.example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup1/providers/Microsoft.LabServices/labs/lab1/users/user1