» azurerm_batch_account

Manages an Azure Batch account.

» Example Usage

resource "azurerm_resource_group" "test" {
  name     = "testbatch"
  location = "westeurope"
}

resource "azurerm_storage_account" "test" {
  name                     = "teststorage"
  resource_group_name      = "${azurerm_resource_group.test.name}"
  location                 = "${azurerm_resource_group.test.location}"
  account_tier             = "Standard"
  account_replication_type = "LRS"
}

resource "azurerm_batch_account" "test" {
  name                 = "testbatchaccount"
  resource_group_name  = "${azurerm_resource_group.test.name}"
  location             = "${azurerm_resource_group.test.location}"
  pool_allocation_mode = "BatchService"
  storage_account_id   = "${azurerm_storage_account.test.id}"

  tags = {
    env = "test"
  }
}

» Argument Reference

The following arguments are supported:

  • name - (Required) Specifies the name of the Batch account. Changing this forces a new resource to be created.

  • resource_group_name - (Required) The name of the resource group in which to create the Batch account. Changing this forces a new resource to be created.

  • location - (Required) Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.

  • pool_allocation_mode - (Optional) Specifies the mode to use for pool allocation. Possible values are BatchService or UserSubscription. Defaults to BatchService.

  • storage_account_id - (Optional) Specifies the storage account to use for the Batch account. If not specified, Azure Batch will manage the storage.

  • tags - (Optional) A mapping of tags to assign to the resource.

» Attributes Reference

The following attributes are exported: