/* * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ import { BaseResource, CloudError } from "ms-rest-azure"; import * as moment from "moment"; export { BaseResource, CloudError }; /** * The properties related to the auto-storage account. */ export interface AutoStorageBaseProperties { /** * The resource ID of the storage account to be used for auto-storage account. */ storageAccountId: string; } export interface KeyVaultProperties { /** * Full path to the versioned secret. Example * https://mykeyvault.vault.azure.net/keys/testkey/6e34a81fef704045975661e297a4c053 */ keyIdentifier?: string; } export interface EncryptionProperties { /** * Type of the key source. Possible values include: 'Microsoft.Batch', 'Microsoft.KeyVault' */ keySource?: string; /** * Additional details when using Microsoft.KeyVault */ keyVaultProperties?: KeyVaultProperties; } /** * Identifies the Azure key vault associated with a Batch account. */ export interface KeyVaultReference { /** * The resource ID of the Azure key vault associated with the Batch account. */ id: string; /** * The URL of the Azure key vault associated with the Batch account. */ url: string; } /** * Parameters supplied to the Create operation. */ export interface BatchAccountCreateParameters { /** * The region in which to create the account. */ location: string; /** * The user-specified tags associated with the account. */ tags?: { [propertyName: string]: string }; /** * The properties related to the auto-storage account. */ autoStorage?: AutoStorageBaseProperties; /** * @summary The allocation mode to use for creating pools in the Batch account. * @description The pool allocation mode also affects how clients may authenticate to the Batch * Service API. If the mode is BatchService, clients may authenticate using access keys or Azure * Active Directory. If the mode is UserSubscription, clients must use Azure Active Directory. * The default is BatchService. Possible values include: 'BatchService', 'UserSubscription' */ poolAllocationMode?: string; /** * A reference to the Azure key vault associated with the Batch account. */ keyVaultReference?: KeyVaultReference; /** * @summary The network access type for accessing Azure Batch account. * @description If not specified, the default value is 'enabled'. Possible values include: * 'Enabled', 'Disabled' */ publicNetworkAccess?: string; /** * @summary The encryption configuration for the Batch account. */ encryption?: EncryptionProperties; } /** * Contains information about the auto-storage account associated with a Batch account. */ export interface AutoStorageProperties extends AutoStorageBaseProperties { /** * The UTC time at which storage keys were last synchronized with the Batch account. */ lastKeySync: Date; } /** * A VM Family and its associated core quota for the Batch account. */ export interface VirtualMachineFamilyCoreQuota { /** * The Virtual Machine family name. */ readonly name?: string; /** * The core quota for the VM family for the Batch account. */ readonly coreQuota?: number; } /** * The private endpoint of the private endpoint connection. */ export interface PrivateEndpoint { /** * @summary The ARM resource identifier of the private endpoint. This is of the form * /subscriptions/{subscription}/resourceGroups/{group}/providers/Microsoft.Network/privateEndpoints/{privateEndpoint}. */ readonly id?: string; } /** * The private link service connection state of the private endpoint connection */ export interface PrivateLinkServiceConnectionState { /** * @summary The status for the private endpoint connection of Batch account * @description Possible values include: 'Approved', 'Pending', 'Rejected', 'Disconnected' */ status: string; /** * @summary Description of the private Connection state */ description?: string; /** * @summary Action required on the private connection state */ readonly actionRequired?: string; } /** * A definition of an Azure resource. */ export interface ProxyResource extends BaseResource { /** * The ID of the resource. */ readonly id?: string; /** * The name of the resource. */ readonly name?: string; /** * The type of the resource. */ readonly type?: string; /** * The ETag of the resource, used for concurrency statements. */ readonly etag?: string; } /** * Contains information about a private link resource. */ export interface PrivateEndpointConnection extends ProxyResource { /** * @summary The provisioning state of the private endpoint connection. * @description Possible values include: 'Succeeded', 'Updating', 'Failed' */ readonly provisioningState?: string; /** * @summary The ARM resource identifier of the private endpoint. */ privateEndpoint?: PrivateEndpoint; /** * @summary The private link service connection state of the private endpoint connection. */ privateLinkServiceConnectionState?: PrivateLinkServiceConnectionState; } /** * A definition of an Azure resource. */ export interface Resource extends BaseResource { /** * The ID of the resource. */ readonly id?: string; /** * The name of the resource. */ readonly name?: string; /** * The type of the resource. */ readonly type?: string; /** * The location of the resource. */ readonly location?: string; /** * The tags of the resource. */ readonly tags?: { [propertyName: string]: string }; } /** * Contains information about an Azure Batch account. */ export interface BatchAccount extends Resource { /** * The account endpoint used to interact with the Batch service. */ readonly accountEndpoint?: string; /** * The provisioned state of the resource. Possible values include: 'Invalid', 'Creating', * 'Deleting', 'Succeeded', 'Failed', 'Cancelled' */ readonly provisioningState?: string; /** * @summary The allocation mode to use for creating pools in the Batch account. * @description Possible values include: 'BatchService', 'UserSubscription' */ readonly poolAllocationMode?: string; /** * @summary A reference to the Azure key vault associated with the Batch account. */ readonly keyVaultReference?: KeyVaultReference; /** * @summary The network interface type for accessing Azure Batch service and Batch account * operations. * @description If not specified, the default value is 'enabled'. Possible values include: * 'Enabled', 'Disabled' */ readonly publicNetworkAccess?: string; /** * List of private endpoint connections associated with the Batch account */ readonly privateEndpointConnections?: PrivateEndpointConnection[]; /** * @summary The properties and status of any auto-storage account associated with the Batch * account. */ readonly autoStorage?: AutoStorageProperties; /** * @summary The encryption configuration for the Batch account. */ readonly encryption?: EncryptionProperties; /** * @summary The dedicated core quota for the Batch account. * @description For accounts with PoolAllocationMode set to UserSubscription, quota is managed on * the subscription so this value is not returned. */ readonly dedicatedCoreQuota?: number; /** * @summary The low-priority core quota for the Batch account. * @description For accounts with PoolAllocationMode set to UserSubscription, quota is managed on * the subscription so this value is not returned. */ readonly lowPriorityCoreQuota?: number; /** * A list of the dedicated core quota per Virtual Machine family for the Batch account. For * accounts with PoolAllocationMode set to UserSubscription, quota is managed on the subscription * so this value is not returned. */ readonly dedicatedCoreQuotaPerVMFamily?: VirtualMachineFamilyCoreQuota[]; /** * @summary A value indicating whether the core quota for the Batch Account is enforced per * Virtual Machine family or not. * @description Batch is transitioning its core quota system for dedicated cores to be enforced * per Virtual Machine family. During this transitional phase, the dedicated core quota per * Virtual Machine family may not yet be enforced. If this flag is false, dedicated core quota is * enforced via the old dedicatedCoreQuota property on the account and does not consider Virtual * Machine family. If this flag is true, dedicated core quota is enforced via the * dedicatedCoreQuotaPerVMFamily property on the account, and the old dedicatedCoreQuota does not * apply. */ readonly dedicatedCoreQuotaPerVMFamilyEnforced?: boolean; /** * @summary The pool quota for the Batch account. */ readonly poolQuota?: number; /** * @summary The active job and job schedule quota for the Batch account. */ readonly activeJobAndJobScheduleQuota?: number; } /** * Parameters for updating an Azure Batch account. */ export interface BatchAccountUpdateParameters { /** * The user-specified tags associated with the account. */ tags?: { [propertyName: string]: string }; /** * The properties related to the auto-storage account. */ autoStorage?: AutoStorageBaseProperties; /** * @summary The encryption configuration for the Batch account. */ encryption?: EncryptionProperties; } /** * Parameters supplied to the RegenerateKey operation. */ export interface BatchAccountRegenerateKeyParameters { /** * The type of account key to regenerate. Possible values include: 'Primary', 'Secondary' */ keyName: string; } /** * A set of Azure Batch account keys. */ export interface BatchAccountKeys { /** * The Batch account name. */ readonly accountName?: string; /** * The primary key associated with the account. */ readonly primary?: string; /** * The secondary key associated with the account. */ readonly secondary?: string; } /** * Parameters for an activating an application package. */ export interface ActivateApplicationPackageParameters { /** * The format of the application package binary file. */ format: string; } /** * Contains information about an application in a Batch account. */ export interface Application extends ProxyResource { /** * The display name for the application. */ displayName?: string; /** * A value indicating whether packages within the application may be overwritten using the same * version string. */ allowUpdates?: boolean; /** * The package to use if a client requests the application but does not specify a version. This * property can only be set to the name of an existing package. */ defaultVersion?: string; } /** * An application package which represents a particular version of an application. */ export interface ApplicationPackage extends ProxyResource { /** * The current state of the application package. Possible values include: 'Pending', 'Active' */ readonly state?: string; /** * The format of the application package, if the package is active. */ readonly format?: string; /** * The URL for the application package in Azure Storage. */ readonly storageUrl?: string; /** * The UTC time at which the Azure Storage URL will expire. */ readonly storageUrlExpiry?: Date; /** * The time at which the package was last activated, if the package is active. */ readonly lastActivationTime?: Date; } /** * Quotas associated with a Batch region for a particular subscription. */ export interface BatchLocationQuota { /** * The number of Batch accounts that may be created under the subscription in the specified * region. */ readonly accountQuota?: number; } export interface CertificateBaseProperties { /** * @summary The algorithm of the certificate thumbprint. * @description This must match the first portion of the certificate name. Currently required to * be 'SHA1'. */ thumbprintAlgorithm?: string; /** * @summary The thumbprint of the certificate. * @description This must match the thumbprint from the name. */ thumbprint?: string; /** * The format of the certificate - either Pfx or Cer. If omitted, the default is Pfx. Possible * values include: 'Pfx', 'Cer' */ format?: string; } /** * An error response from the Batch service. */ export interface DeleteCertificateError { /** * An identifier for the error. Codes are invariant and are intended to be consumed * programmatically. */ code: string; /** * A message describing the error, intended to be suitable for display in a user interface. */ message: string; /** * The target of the particular error. For example, the name of the property in error. */ target?: string; /** * A list of additional details about the error. */ details?: DeleteCertificateError[]; } /** * Contains information about a certificate. */ export interface Certificate extends ProxyResource { /** * @summary The algorithm of the certificate thumbprint. * @description This must match the first portion of the certificate name. Currently required to * be 'SHA1'. */ thumbprintAlgorithm?: string; /** * @summary The thumbprint of the certificate. * @description This must match the thumbprint from the name. */ thumbprint?: string; /** * The format of the certificate - either Pfx or Cer. If omitted, the default is Pfx. Possible * values include: 'Pfx', 'Cer' */ format?: string; /** * @summary The provisioned state of the resource * @description Possible values include: 'Succeeded', 'Deleting', 'Failed' */ readonly provisioningState?: string; /** * @summary The time at which the certificate entered its current state. */ readonly provisioningStateTransitionTime?: Date; /** * The previous provisioned state of the resource. Possible values include: 'Succeeded', * 'Deleting', 'Failed' */ readonly previousProvisioningState?: string; /** * @summary The time at which the certificate entered its previous state. */ readonly previousProvisioningStateTransitionTime?: Date; /** * The public key of the certificate. */ readonly publicData?: string; /** * @summary The error which occurred while deleting the certificate * @description This is only returned when the certificate provisioningState is 'Failed'. */ readonly deleteCertificateError?: DeleteCertificateError; } /** * Contains information about a certificate. */ export interface CertificateCreateOrUpdateParameters extends ProxyResource { /** * @summary The algorithm of the certificate thumbprint. * @description This must match the first portion of the certificate name. Currently required to * be 'SHA1'. */ thumbprintAlgorithm?: string; /** * @summary The thumbprint of the certificate. * @description This must match the thumbprint from the name. */ thumbprint?: string; /** * The format of the certificate - either Pfx or Cer. If omitted, the default is Pfx. Possible * values include: 'Pfx', 'Cer' */ format?: string; /** * @summary The base64-encoded contents of the certificate. * @description The maximum size is 10KB. */ data: string; /** * @summary The password to access the certificate's private key. * @description This must not be specified if the certificate format is Cer. */ password?: string; } /** * Contains information about a private link resource. */ export interface PrivateLinkResource extends ProxyResource { /** * @summary The group id of the private link resource. * @description The group id is used to establish the private link connection. */ readonly groupId?: string; /** * @summary The list of required members that are used to establish the private link connection. */ readonly requiredMembers?: string[]; /** * @summary The list of required zone names for the private DNS resource name */ readonly requiredZoneNames?: string[]; } /** * @summary The configuration for nodes in a pool based on the Azure Cloud Services platform. */ export interface CloudServiceConfiguration { /** * @summary The Azure Guest OS family to be installed on the virtual machines in the pool. * @description Possible values are: 2 - OS Family 2, equivalent to Windows Server 2008 R2 SP1. 3 * - OS Family 3, equivalent to Windows Server 2012. 4 - OS Family 4, equivalent to Windows * Server 2012 R2. 5 - OS Family 5, equivalent to Windows Server 2016. 6 - OS Family 6, * equivalent to Windows Server 2019. For more information, see Azure Guest OS Releases * (https://azure.microsoft.com/documentation/articles/cloud-services-guestos-update-matrix/#releases). */ osFamily: string; /** * @summary The Azure Guest OS version to be installed on the virtual machines in the pool. * @description The default value is * which specifies the latest operating system version for * the specified OS family. */ osVersion?: string; } /** * @summary A reference to an Azure Virtual Machines Marketplace image or the Azure Image resource * of a custom Virtual Machine. To get the list of all imageReferences verified by Azure Batch, see * the 'List supported node agent SKUs' operation. */ export interface ImageReference { /** * @summary The publisher of the Azure Virtual Machines Marketplace image. * @description For example, Canonical or MicrosoftWindowsServer. */ publisher?: string; /** * @summary The offer type of the Azure Virtual Machines Marketplace image. * @description For example, UbuntuServer or WindowsServer. */ offer?: string; /** * @summary The SKU of the Azure Virtual Machines Marketplace image. * @description For example, 18.04-LTS or 2019-Datacenter. */ sku?: string; /** * @summary The version of the Azure Virtual Machines Marketplace image. * @description A value of 'latest' can be specified to select the latest version of an image. If * omitted, the default is 'latest'. */ version?: string; /** * @summary The ARM resource identifier of the Shared Image Gallery Image. Compute Nodes in the * Pool will be created using this Image Id. This is of the form * /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{versionId}. * @description This property is mutually exclusive with other properties. The Shared Image * Gallery image must have replicas in the same region as the Azure Batch account. For * information about the firewall settings for the Batch node agent to communicate with the Batch * service see * https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration. */ id?: string; } /** * @summary Windows operating system settings to apply to the virtual machine. */ export interface WindowsConfiguration { /** * @summary Whether automatic updates are enabled on the virtual machine. * @description If omitted, the default value is true. */ enableAutomaticUpdates?: boolean; } /** * Settings which will be used by the data disks associated to Compute Nodes in the Pool. When * using attached data disks, you need to mount and format the disks from within a VM to use them. */ export interface DataDisk { /** * @summary The logical unit number. * @description The lun is used to uniquely identify each data disk. If attaching multiple disks, * each should have a distinct lun. */ lun: number; /** * @summary The type of caching to be enabled for the data disks. * @description Values are: * * none - The caching mode for the disk is not enabled. * readOnly - The caching mode for the disk is read only. * readWrite - The caching mode for the disk is read and write. * * The default value for caching is none. For information about the caching options see: * https://blogs.msdn.microsoft.com/windowsazurestorage/2012/06/27/exploring-windows-azure-drives-disks-and-images/. * Possible values include: 'None', 'ReadOnly', 'ReadWrite' */ caching?: string; /** * @summary The initial disk size in GB when creating new data disk. */ diskSizeGB: number; /** * @summary The storage account type to be used for the data disk. * @description If omitted, the default is "Standard_LRS". Values are: * * Standard_LRS - The data disk should use standard locally redundant storage. * Premium_LRS - The data disk should use premium locally redundant storage. Possible values * include: 'Standard_LRS', 'Premium_LRS' */ storageAccountType?: string; } /** * @summary A private container registry. */ export interface ContainerRegistry { /** * @summary The registry URL. * @description If omitted, the default is "docker.io". */ registryServer?: string; /** * @summary The user name to log into the registry server. */ userName: string; /** * @summary The password to log into the registry server. */ password: string; } /** * @summary The configuration for container-enabled pools. */ export interface ContainerConfiguration { /** * @summary The collection of container image names. * @description This is the full image reference, as would be specified to "docker pull". An * image will be sourced from the default Docker registry unless the image is fully qualified * with an alternative registry. */ containerImageNames?: string[]; /** * @summary Additional private registries from which containers can be pulled. * @description If any images must be downloaded from a private registry which requires * credentials, then those credentials must be provided here. */ containerRegistries?: ContainerRegistry[]; } /** * The disk encryption configuration applied on compute nodes in the pool. Disk encryption * configuration is not supported on Linux pool created with Virtual Machine Image or Shared Image * Gallery Image. */ export interface DiskEncryptionConfiguration { /** * @summary The list of disk targets Batch Service will encrypt on the compute node * @description On Linux pool, only "TemporaryDisk" is supported; on Windows pool, "OsDisk" and * "TemporaryDisk" must be specified. */ targets?: string[]; } /** * @summary The configuration for compute nodes in a pool based on the Azure Virtual Machines * infrastructure. */ export interface VirtualMachineConfiguration { /** * @summary A reference to the Azure Virtual Machines Marketplace Image or the custom Virtual * Machine Image to use. */ imageReference: ImageReference; /** * @summary The SKU of the Batch node agent to be provisioned on compute nodes in the pool. * @description The Batch node agent is a program that runs on each node in the pool, and * provides the command-and-control interface between the node and the Batch service. There are * different implementations of the node agent, known as SKUs, for different operating systems. * You must specify a node agent SKU which matches the selected image reference. To get the list * of supported node agent SKUs along with their list of verified image references, see the 'List * supported node agent SKUs' operation. */ nodeAgentSkuId: string; /** * @summary Windows operating system settings on the virtual machine. * @description This property must not be specified if the imageReference specifies a Linux OS * image. */ windowsConfiguration?: WindowsConfiguration; /** * @summary The configuration for data disks attached to the compute nodes in the pool. * @description This property must be specified if the compute nodes in the pool need to have * empty data disks attached to them. */ dataDisks?: DataDisk[]; /** * @summary The type of on-premises license to be used when deploying the operating system. * @description This only applies to images that contain the Windows operating system, and should * only be used when you hold valid on-premises licenses for the nodes which will be deployed. If * omitted, no on-premises licensing discount is applied. Values are: * * Windows_Server - The on-premises license is for Windows Server. * Windows_Client - The on-premises license is for Windows Client. */ licenseType?: string; /** * @summary The container configuration for the pool. * @description If specified, setup is performed on each node in the pool to allow tasks to run * in containers. All regular tasks and job manager tasks run on this pool must specify the * containerSettings property, and all other tasks may specify it. */ containerConfiguration?: ContainerConfiguration; /** * @summary The disk encryption configuration for the pool. * @description If specified, encryption is performed on each node in the pool during node * provisioning. */ diskEncryptionConfiguration?: DiskEncryptionConfiguration; } /** * @summary Deployment configuration properties. */ export interface DeploymentConfiguration { /** * @summary The cloud service configuration for the pool. * @description This property and virtualMachineConfiguration are mutually exclusive and one of * the properties must be specified. This property cannot be specified if the Batch account was * created with its poolAllocationMode property set to 'UserSubscription'. */ cloudServiceConfiguration?: CloudServiceConfiguration; /** * @summary The virtual machine configuration for the pool. * @description This property and cloudServiceConfiguration are mutually exclusive and one of the * properties must be specified. */ virtualMachineConfiguration?: VirtualMachineConfiguration; } /** * @summary Fixed scale settings for the pool. */ export interface FixedScaleSettings { /** * @summary The timeout for allocation of compute nodes to the pool. * @description The default value is 15 minutes. Timeout values use ISO 8601 format. For example, * use PT10M for 10 minutes. The minimum value is 5 minutes. If you specify a value less than 5 * minutes, the Batch service rejects the request with an error; if you are calling the REST API * directly, the HTTP status code is 400 (Bad Request). */ resizeTimeout?: moment.Duration; /** * @summary The desired number of dedicated compute nodes in the pool. * @description At least one of targetDedicatedNodes, targetLowPriorityNodes must be set. */ targetDedicatedNodes?: number; /** * @summary The desired number of low-priority compute nodes in the pool. * @description At least one of targetDedicatedNodes, targetLowPriorityNodes must be set. */ targetLowPriorityNodes?: number; /** * @summary Determines what to do with a node and its running task(s) if the pool size is * decreasing. * @description If omitted, the default value is Requeue. Possible values include: 'Requeue', * 'Terminate', 'TaskCompletion', 'RetainedData' */ nodeDeallocationOption?: string; } /** * @summary AutoScale settings for the pool. */ export interface AutoScaleSettings { /** * @summary A formula for the desired number of compute nodes in the pool. */ formula: string; /** * @summary The time interval at which to automatically adjust the pool size according to the * autoscale formula. * @description If omitted, the default value is 15 minutes (PT15M). */ evaluationInterval?: moment.Duration; } /** * @summary Scale settings for the pool * @description Defines the desired size of the pool. This can either be 'fixedScale' where the * requested targetDedicatedNodes is specified, or 'autoScale' which defines a formula which is * periodically reevaluated. If this property is not specified, the pool will have a fixed scale * with 0 targetDedicatedNodes. */ export interface ScaleSettings { /** * @summary Fixed scale settings for the pool. * @description This property and autoScale are mutually exclusive and one of the properties must * be specified. */ fixedScale?: FixedScaleSettings; /** * @summary AutoScale settings for the pool. * @description This property and fixedScale are mutually exclusive and one of the properties * must be specified. */ autoScale?: AutoScaleSettings; } /** * @summary An error that occurred when autoscaling a pool. */ export interface AutoScaleRunError { /** * An identifier for the error. Codes are invariant and are intended to be consumed * programmatically. */ code: string; /** * A message describing the error, intended to be suitable for display in a user interface. */ message: string; /** * @summary Additional details about the error. */ details?: AutoScaleRunError[]; } /** * @summary The results and errors from an execution of a pool autoscale formula. */ export interface AutoScaleRun { /** * @summary The time at which the autoscale formula was last evaluated. */ evaluationTime: Date; /** * @summary The final values of all variables used in the evaluation of the autoscale formula. * @description Each variable value is returned in the form $variable=value, and variables are * separated by semicolons. */ results?: string; /** * @summary Details of the error encountered evaluating the autoscale formula on the pool, if the * evaluation was unsuccessful. */ error?: AutoScaleRunError; } /** * @summary A network security group rule to apply to an inbound endpoint. */ export interface NetworkSecurityGroupRule { /** * @summary The priority for this rule. * @description Priorities within a pool must be unique and are evaluated in order of priority. * The lower the number the higher the priority. For example, rules could be specified with order * numbers of 150, 250, and 350. The rule with the order number of 150 takes precedence over the * rule that has an order of 250. Allowed priorities are 150 to 4096. If any reserved or * duplicate values are provided the request fails with HTTP status code 400. */ priority: number; /** * @summary The action that should be taken for a specified IP address, subnet range or tag. * @description Possible values include: 'Allow', 'Deny' */ access: string; /** * @summary The source address prefix or tag to match for the rule. * @description Valid values are a single IP address (i.e. 10.10.10.10), IP subnet (i.e. * 192.168.1.0/24), default tag, or * (for all addresses). If any other values are provided the * request fails with HTTP status code 400. */ sourceAddressPrefix: string; /** * @summary The source port ranges to match for the rule. * @description Valid values are '*' (for all ports 0 - 65535) or arrays of ports or port ranges * (i.e. 100-200). The ports should in the range of 0 to 65535 and the port ranges or ports can't * overlap. If any other values are provided the request fails with HTTP status code 400. Default * value will be *. */ sourcePortRanges?: string[]; } /** * @summary A inbound NAT pool that can be used to address specific ports on compute nodes in a * Batch pool externally. */ export interface InboundNatPool { /** * @summary The name of the endpoint. * @description The name must be unique within a Batch pool, can contain letters, numbers, * underscores, periods, and hyphens. Names must start with a letter or number, must end with a * letter, number, or underscore, and cannot exceed 77 characters. If any invalid values are * provided the request fails with HTTP status code 400. */ name: string; /** * @summary The protocol of the endpoint. * @description Possible values include: 'TCP', 'UDP' */ protocol: string; /** * @summary The port number on the compute node. * @description This must be unique within a Batch pool. Acceptable values are between 1 and * 65535 except for 22, 3389, 29876 and 29877 as these are reserved. If any reserved values are * provided the request fails with HTTP status code 400. */ backendPort: number; /** * @summary The first port number in the range of external ports that will be used to provide * inbound access to the backendPort on individual compute nodes. * @description Acceptable values range between 1 and 65534 except ports from 50000 to 55000 * which are reserved. All ranges within a pool must be distinct and cannot overlap. If any * reserved or overlapping values are provided the request fails with HTTP status code 400. */ frontendPortRangeStart: number; /** * @summary The last port number in the range of external ports that will be used to provide * inbound access to the backendPort on individual compute nodes. * @description Acceptable values range between 1 and 65534 except ports from 50000 to 55000 * which are reserved by the Batch service. All ranges within a pool must be distinct and cannot * overlap. If any reserved or overlapping values are provided the request fails with HTTP status * code 400. */ frontendPortRangeEnd: number; /** * @summary A list of network security group rules that will be applied to the endpoint. * @description The maximum number of rules that can be specified across all the endpoints on a * Batch pool is 25. If no network security group rules are specified, a default rule will be * created to allow inbound access to the specified backendPort. If the maximum number of network * security group rules is exceeded the request fails with HTTP status code 400. */ networkSecurityGroupRules?: NetworkSecurityGroupRule[]; } /** * @summary The endpoint configuration for a pool. */ export interface PoolEndpointConfiguration { /** * @summary A list of inbound NAT pools that can be used to address specific ports on an * individual compute node externally. * @description The maximum number of inbound NAT pools per Batch pool is 5. If the maximum * number of inbound NAT pools is exceeded the request fails with HTTP status code 400. */ inboundNatPools: InboundNatPool[]; } /** * The public IP Address configuration of the networking configuration of a Pool. */ export interface PublicIPAddressConfiguration { /** * @summary The provisioning type for Public IP Addresses for the pool * @description The default value is BatchManaged. Possible values include: 'BatchManaged', * 'UserManaged', 'NoPublicIPAddresses' */ provision?: string; /** * @summary The list of public IPs which the Batch service will use when provisioning Compute * Nodes. * @description The number of IPs specified here limits the maximum size of the Pool - 50 * dedicated nodes or 20 low-priority nodes can be allocated for each public IP. For example, a * pool needing 150 dedicated VMs would need at least 3 public IPs specified. Each element of * this collection is of the form: * /subscriptions/{subscription}/resourceGroups/{group}/providers/Microsoft.Network/publicIPAddresses/{ip}. */ ipAddressIds?: string[]; } /** * The network configuration for a pool. */ export interface NetworkConfiguration { /** * @summary The ARM resource identifier of the virtual network subnet which the compute nodes of * the pool will join. This is of the form * /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. * @description The virtual network must be in the same region and subscription as the Azure * Batch account. The specified subnet should have enough free IP addresses to accommodate the * number of nodes in the pool. If the subnet doesn't have enough free IP addresses, the pool * will partially allocate compute nodes and a resize error will occur. The 'MicrosoftAzureBatch' * service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access * Control (RBAC) role for the specified VNet. The specified subnet must allow communication from * the Azure Batch service to be able to schedule tasks on the compute nodes. This can be * verified by checking if the specified VNet has any associated Network Security Groups (NSG). * If communication to the compute nodes in the specified subnet is denied by an NSG, then the * Batch service will set the state of the compute nodes to unusable. If the specified VNet has * any associated Network Security Groups (NSG), then a few reserved system ports must be enabled * for inbound communication. For pools created with a virtual machine configuration, enable * ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. For pools * created with a cloud service configuration, enable ports 10100, 20100, and 30100. Also enable * outbound connections to Azure Storage on port 443. For cloudServiceConfiguration pools, only * 'classic' VNETs are supported. For more details see: * https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration */ subnetId?: string; /** * @summary The configuration for endpoints on compute nodes in the Batch pool. * @description Pool endpoint configuration is only supported on pools with the * virtualMachineConfiguration property. */ endpointConfiguration?: PoolEndpointConfiguration; /** * @summary The Public IPAddress configuration for Compute Nodes in the Batch Pool. * @description This property is only supported on Pools with the virtualMachineConfiguration * property. */ publicIPAddressConfiguration?: PublicIPAddressConfiguration; } /** * @summary Specifies how tasks should be distributed across compute nodes. */ export interface TaskSchedulingPolicy { /** * @summary How tasks should be distributed across compute nodes. * @description Possible values include: 'Spread', 'Pack' */ nodeFillType: string; } /** * @summary Properties used to create a user account on a Linux node. */ export interface LinuxUserConfiguration { /** * @summary The user ID of the user account. * @description The uid and gid properties must be specified together or not at all. If not * specified the underlying operating system picks the uid. */ uid?: number; /** * @summary The group ID for the user account. * @description The uid and gid properties must be specified together or not at all. If not * specified the underlying operating system picks the gid. */ gid?: number; /** * @summary The SSH private key for the user account. * @description The private key must not be password protected. The private key is used to * automatically configure asymmetric-key based authentication for SSH between nodes in a Linux * pool when the pool's enableInterNodeCommunication property is true (it is ignored if * enableInterNodeCommunication is false). It does this by placing the key pair into the user's * .ssh directory. If not specified, password-less SSH is not configured between nodes (no * modification of the user's .ssh directory is done). */ sshPrivateKey?: string; } /** * @summary Properties used to create a user account on a Windows node. */ export interface WindowsUserConfiguration { /** * @summary Login mode for user * @description Specifies login mode for the user. The default value for * VirtualMachineConfiguration pools is interactive mode and for CloudServiceConfiguration pools * is batch mode. Possible values include: 'Batch', 'Interactive' */ loginMode?: string; } /** * @summary Properties used to create a user on an Azure Batch node. */ export interface UserAccount { /** * @summary The name of the user account. */ name: string; /** * @summary The password for the user account. */ password: string; /** * @summary The elevation level of the user account. * @description nonAdmin - The auto user is a standard user without elevated access. admin - The * auto user is a user with elevated access and operates with full Administrator permissions. The * default value is nonAdmin. Possible values include: 'NonAdmin', 'Admin' */ elevationLevel?: string; /** * @summary The Linux-specific user configuration for the user account. * @description This property is ignored if specified on a Windows pool. If not specified, the * user is created with the default options. */ linuxUserConfiguration?: LinuxUserConfiguration; /** * @summary The Windows-specific user configuration for the user account. * @description This property can only be specified if the user is on a Windows pool. If not * specified and on a Windows pool, the user is created with the default options. */ windowsUserConfiguration?: WindowsUserConfiguration; } /** * @summary A name-value pair associated with a Batch service resource. * @description The Batch service does not assign any meaning to this metadata; it is solely for * the use of user code. */ export interface MetadataItem { /** * @summary The name of the metadata item. */ name: string; /** * @summary The value of the metadata item. */ value: string; } /** * @summary A single file or multiple files to be downloaded to a compute node. */ export interface ResourceFile { /** * @summary The storage container name in the auto storage account. * @description The autoStorageContainerName, storageContainerUrl and httpUrl properties are * mutually exclusive and one of them must be specified. */ autoStorageContainerName?: string; /** * @summary The URL of the blob container within Azure Blob Storage. * @description The autoStorageContainerName, storageContainerUrl and httpUrl properties are * mutually exclusive and one of them must be specified. This URL must be readable and listable * using anonymous access; that is, the Batch service does not present any credentials when * downloading the blob. There are two ways to get such a URL for a blob in Azure storage: * include a Shared Access Signature (SAS) granting read and list permissions on the blob, or set * the ACL for the blob or its container to allow public access. */ storageContainerUrl?: string; /** * @summary The URL of the file to download. * @description The autoStorageContainerName, storageContainerUrl and httpUrl properties are * mutually exclusive and one of them must be specified. If the URL is Azure Blob Storage, it * must be readable using anonymous access; that is, the Batch service does not present any * credentials when downloading the blob. There are two ways to get such a URL for a blob in * Azure storage: include a Shared Access Signature (SAS) granting read permissions on the blob, * or set the ACL for the blob or its container to allow public access. */ httpUrl?: string; /** * @summary The blob prefix to use when downloading blobs from an Azure Storage container. Only * the blobs whose names begin with the specified prefix will be downloaded. * @description The property is valid only when autoStorageContainerName or storageContainerUrl * is used. This prefix can be a partial filename or a subdirectory. If a prefix is not * specified, all the files in the container will be downloaded. */ blobPrefix?: string; /** * @summary The location on the compute node to which to download the file, relative to the * task's working directory. * @description If the httpUrl property is specified, the filePath is required and describes the * path which the file will be downloaded to, including the filename. Otherwise, if the * autoStorageContainerName or storageContainerUrl property is specified, filePath is optional * and is the directory to download the files to. In the case where filePath is used as a * directory, any directory structure already associated with the input data will be retained in * full and appended to the specified filePath directory. The specified relative path cannot * break out of the task's working directory (for example by using '..'). */ filePath?: string; /** * @summary The file permission mode attribute in octal format. * @description This property applies only to files being downloaded to Linux compute nodes. It * will be ignored if it is specified for a resourceFile which will be downloaded to a Windows * node. If this property is not specified for a Linux node, then a default value of 0770 is * applied to the file. */ fileMode?: string; } /** * @summary An environment variable to be set on a task process. */ export interface EnvironmentSetting { /** * @summary The name of the environment variable. */ name: string; /** * @summary The value of the environment variable. */ value?: string; } /** * @summary Specifies the parameters for the auto user that runs a task on the Batch service. */ export interface AutoUserSpecification { /** * @summary The scope for the auto user * @description The default value is Pool. If the pool is running Windows a value of Task should * be specified if stricter isolation between tasks is required. For example, if the task mutates * the registry in a way which could impact other tasks, or if certificates have been specified * on the pool which should not be accessible by normal tasks but should be accessible by start * tasks. Possible values include: 'Task', 'Pool' */ scope?: string; /** * @summary The elevation level of the auto user. * @description The default value is nonAdmin. Possible values include: 'NonAdmin', 'Admin' */ elevationLevel?: string; } /** * @summary The definition of the user identity under which the task is run. * @description Specify either the userName or autoUser property, but not both. */ export interface UserIdentity { /** * @summary The name of the user identity under which the task is run. * @description The userName and autoUser properties are mutually exclusive; you must specify one * but not both. */ userName?: string; /** * @summary The auto user under which the task is run. * @description The userName and autoUser properties are mutually exclusive; you must specify one * but not both. */ autoUser?: AutoUserSpecification; } /** * @summary The container settings for a task. */ export interface TaskContainerSettings { /** * @summary Additional options to the container create command. * @description These additional options are supplied as arguments to the "docker create" * command, in addition to those controlled by the Batch Service. */ containerRunOptions?: string; /** * @summary The image to use to create the container in which the task will run. * @description This is the full image reference, as would be specified to "docker pull". If no * tag is provided as part of the image name, the tag ":latest" is used as a default. */ imageName: string; /** * @summary The private registry which contains the container image. * @description This setting can be omitted if was already provided at pool creation. */ registry?: ContainerRegistry; /** * @summary A flag to indicate where the container task working directory is. The default is * 'taskWorkingDirectory'. * @description Possible values include: 'TaskWorkingDirectory', 'ContainerImageDefault' */ workingDirectory?: string; } /** * @summary A task which is run when a compute node joins a pool in the Azure Batch service, or * when the compute node is rebooted or reimaged. * @description In some cases the start task may be re-run even though the node was not rebooted. * Due to this, start tasks should be idempotent and exit gracefully if the setup they're * performing has already been done. Special care should be taken to avoid start tasks which create * breakaway process or install/launch services from the start task working directory, as this will * block Batch from being able to re-run the start task. */ export interface StartTask { /** * @summary The command line of the start task. * @description The command line does not run under a shell, and therefore cannot take advantage * of shell features such as environment variable expansion. If you want to take advantage of * such features, you should invoke the shell in the command line, for example using "cmd /c * MyCommand" in Windows or "/bin/sh -c MyCommand" in Linux. Required if any other properties of * the startTask are specified. */ commandLine?: string; /** * @summary A list of files that the Batch service will download to the compute node before * running the command line. */ resourceFiles?: ResourceFile[]; /** * @summary A list of environment variable settings for the start task. */ environmentSettings?: EnvironmentSetting[]; /** * @summary The user identity under which the start task runs. * @description If omitted, the task runs as a non-administrative user unique to the task. */ userIdentity?: UserIdentity; /** * @summary The maximum number of times the task may be retried. * @description The Batch service retries a task if its exit code is nonzero. Note that this * value specifically controls the number of retries. The Batch service will try the task once, * and may then retry up to this limit. For example, if the maximum retry count is 3, Batch tries * the task up to 4 times (one initial try and 3 retries). If the maximum retry count is 0, the * Batch service does not retry the task. If the maximum retry count is -1, the Batch service * retries the task without limit. */ maxTaskRetryCount?: number; /** * @summary Whether the Batch service should wait for the start task to complete successfully * (that is, to exit with exit code 0) before scheduling any tasks on the compute node. * @description If true and the start task fails on a compute node, the Batch service retries the * start task up to its maximum retry count (maxTaskRetryCount). If the task has still not * completed successfully after all retries, then the Batch service marks the compute node * unusable, and will not schedule tasks to it. This condition can be detected via the node state * and scheduling error detail. If false, the Batch service will not wait for the start task to * complete. In this case, other tasks can start executing on the compute node while the start * task is still running; and even if the start task fails, new tasks will continue to be * scheduled on the node. The default is true. */ waitForSuccess?: boolean; /** * @summary The settings for the container under which the start task runs. * @description When this is specified, all directories recursively below the * AZ_BATCH_NODE_ROOT_DIR (the root of Azure Batch directories on the node) are mapped into the * container, all task environment variables are mapped into the container, and the task command * line is executed in the container. */ containerSettings?: TaskContainerSettings; } /** * @summary A reference to a certificate to be installed on compute nodes in a pool. This must * exist inside the same account as the pool. */ export interface CertificateReference { /** * @summary The fully qualified ID of the certificate to install on the pool. This must be inside * the same batch account as the pool. */ id: string; /** * @summary The location of the certificate store on the compute node into which to install the * certificate. * @description The default value is currentUser. This property is applicable only for pools * configured with Windows nodes (that is, created with cloudServiceConfiguration, or with * virtualMachineConfiguration using a Windows image reference). For Linux compute nodes, the * certificates are stored in a directory inside the task working directory and an environment * variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For * certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's * home directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory. * Possible values include: 'CurrentUser', 'LocalMachine' */ storeLocation?: string; /** * @summary The name of the certificate store on the compute node into which to install the * certificate. * @description This property is applicable only for pools configured with Windows nodes (that * is, created with cloudServiceConfiguration, or with virtualMachineConfiguration using a * Windows image reference). Common store names include: My, Root, CA, Trust, Disallowed, * TrustedPeople, TrustedPublisher, AuthRoot, AddressBook, but any custom store name can also be * used. The default value is My. */ storeName?: string; /** * @summary Which user accounts on the compute node should have access to the private data of the * certificate. */ visibility?: string[]; } /** * @summary Link to an application package inside the batch account */ export interface ApplicationPackageReference { /** * @summary The ID of the application package to install. This must be inside the same batch * account as the pool. This can either be a reference to a specific version or the default * version if one exists. */ id: string; /** * @summary The version of the application to deploy. If omitted, the default version is * deployed. * @description If this is omitted, and no default version is specified for this application, the * request fails with the error code InvalidApplicationPackageReferences. If you are calling the * REST API directly, the HTTP status code is 409. */ version?: string; } /** * @summary An error that occurred when resizing a pool. */ export interface ResizeError { /** * An identifier for the error. Codes are invariant and are intended to be consumed * programmatically. */ code: string; /** * A message describing the error, intended to be suitable for display in a user interface. */ message: string; /** * @summary Additional details about the error. */ details?: ResizeError[]; } /** * @summary Details about the current or last completed resize operation. * @description Describes either the current operation (if the pool AllocationState is Resizing) or * the previously completed operation (if the AllocationState is Steady). */ export interface ResizeOperationStatus { /** * @summary The desired number of dedicated compute nodes in the pool. */ targetDedicatedNodes?: number; /** * @summary The desired number of low-priority compute nodes in the pool. */ targetLowPriorityNodes?: number; /** * @summary The timeout for allocation of compute nodes to the pool or removal of compute nodes * from the pool. * @description The default value is 15 minutes. The minimum value is 5 minutes. If you specify a * value less than 5 minutes, the Batch service returns an error; if you are calling the REST API * directly, the HTTP status code is 400 (Bad Request). */ resizeTimeout?: moment.Duration; /** * @summary Determines what to do with a node and its running task(s) if the pool size is * decreasing. * @description The default value is requeue. Possible values include: 'Requeue', 'Terminate', * 'TaskCompletion', 'RetainedData' */ nodeDeallocationOption?: string; /** * @summary The time when this resize operation was started. */ startTime?: Date; /** * @summary Details of any errors encountered while performing the last resize on the pool. * @description This property is set only if an error occurred during the last pool resize, and * only when the pool allocationState is Steady. */ errors?: ResizeError[]; } /** * @summary Information used to connect to an Azure Storage Container using Blobfuse. */ export interface AzureBlobFileSystemConfiguration { /** * @summary The Azure Storage Account name. */ accountName: string; /** * @summary The Azure Blob Storage Container name. */ containerName: string; /** * @summary The Azure Storage Account key. * @description This property is mutually exclusive with sasKey and one must be specified. */ accountKey?: string; /** * @summary The Azure Storage SAS token. * @description This property is mutually exclusive with accountKey and one must be specified. */ sasKey?: string; /** * @summary Additional command line options to pass to the mount command. * @description These are 'net use' options in Windows and 'mount' options in Linux. */ blobfuseOptions?: string; /** * @summary The relative path on the compute node where the file system will be mounted * @description All file systems are mounted relative to the Batch mounts directory, accessible * via the AZ_BATCH_NODE_MOUNTS_DIR environment variable. */ relativeMountPath: string; } /** * @summary Information used to connect to an NFS file system. */ export interface NFSMountConfiguration { /** * @summary The URI of the file system to mount. */ source: string; /** * @summary The relative path on the compute node where the file system will be mounted * @description All file systems are mounted relative to the Batch mounts directory, accessible * via the AZ_BATCH_NODE_MOUNTS_DIR environment variable. */ relativeMountPath: string; /** * @summary Additional command line options to pass to the mount command. * @description These are 'net use' options in Windows and 'mount' options in Linux. */ mountOptions?: string; } /** * @summary Information used to connect to a CIFS file system. */ export interface CIFSMountConfiguration { /** * @summary The user to use for authentication against the CIFS file system. */ username: string; /** * @summary The URI of the file system to mount. */ source: string; /** * @summary The relative path on the compute node where the file system will be mounted * @description All file systems are mounted relative to the Batch mounts directory, accessible * via the AZ_BATCH_NODE_MOUNTS_DIR environment variable. */ relativeMountPath: string; /** * @summary Additional command line options to pass to the mount command. * @description These are 'net use' options in Windows and 'mount' options in Linux. */ mountOptions?: string; /** * @summary The password to use for authentication against the CIFS file system. */ password: string; } /** * @summary Information used to connect to an Azure Fileshare. */ export interface AzureFileShareConfiguration { /** * @summary The Azure Storage account name. */ accountName: string; /** * @summary The Azure Files URL. * @description This is of the form 'https://{account}.file.core.windows.net/'. */ azureFileUrl: string; /** * @summary The Azure Storage account key. */ accountKey: string; /** * @summary The relative path on the compute node where the file system will be mounted * @description All file systems are mounted relative to the Batch mounts directory, accessible * via the AZ_BATCH_NODE_MOUNTS_DIR environment variable. */ relativeMountPath: string; /** * @summary Additional command line options to pass to the mount command. * @description These are 'net use' options in Windows and 'mount' options in Linux. */ mountOptions?: string; } /** * @summary The file system to mount on each node. */ export interface MountConfiguration { /** * @summary The Azure Storage Container to mount using blob FUSE on each node. * @description This property is mutually exclusive with all other properties. */ azureBlobFileSystemConfiguration?: AzureBlobFileSystemConfiguration; /** * @summary The NFS file system to mount on each node. * @description This property is mutually exclusive with all other properties. */ nfsMountConfiguration?: NFSMountConfiguration; /** * @summary The CIFS/SMB file system to mount on each node. * @description This property is mutually exclusive with all other properties. */ cifsMountConfiguration?: CIFSMountConfiguration; /** * @summary The Azure File Share to mount on each node. * @description This property is mutually exclusive with all other properties. */ azureFileShareConfiguration?: AzureFileShareConfiguration; } /** * Contains information about a pool. */ export interface Pool extends ProxyResource { /** * @summary The display name for the pool. * @description The display name need not be unique and can contain any Unicode characters up to * a maximum length of 1024. */ displayName?: string; /** * @summary The last modified time of the pool. * @description This is the last time at which the pool level data, such as the * targetDedicatedNodes or autoScaleSettings, changed. It does not factor in node-level changes * such as a compute node changing state. */ readonly lastModified?: Date; /** * @summary The creation time of the pool. */ readonly creationTime?: Date; /** * @summary The current state of the pool. * @description Possible values include: 'Succeeded', 'Deleting' */ readonly provisioningState?: string; /** * @summary The time at which the pool entered its current state. */ readonly provisioningStateTransitionTime?: Date; /** * @summary Whether the pool is resizing. * @description Possible values include: 'Steady', 'Resizing', 'Stopping' */ readonly allocationState?: string; /** * @summary The time at which the pool entered its current allocation state. */ readonly allocationStateTransitionTime?: Date; /** * @summary The size of virtual machines in the pool. All VMs in a pool are the same size. * @description For information about available sizes of virtual machines for Cloud Services * pools (pools created with cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch * supports all Cloud Services VM sizes except ExtraSmall. For information about available VM * sizes for pools using images from the Virtual Machines Marketplace (pools created with * virtualMachineConfiguration) see Sizes for Virtual Machines (Linux) * (https://azure.microsoft.com/documentation/articles/virtual-machines-linux-sizes/) or Sizes * for Virtual Machines (Windows) * (https://azure.microsoft.com/documentation/articles/virtual-machines-windows-sizes/). Batch * supports all Azure VM sizes except STANDARD_A0 and those with premium storage (STANDARD_GS, * STANDARD_DS, and STANDARD_DSV2 series). */ vmSize?: string; /** * @summary This property describes how the pool nodes will be deployed - using Cloud Services or * Virtual Machines. * @description Using CloudServiceConfiguration specifies that the nodes should be creating using * Azure Cloud Services (PaaS), while VirtualMachineConfiguration uses Azure Virtual Machines * (IaaS). */ deploymentConfiguration?: DeploymentConfiguration; /** * @summary The number of compute nodes currently in the pool. */ readonly currentDedicatedNodes?: number; /** * @summary The number of low priority compute nodes currently in the pool. */ readonly currentLowPriorityNodes?: number; /** * @summary Settings which configure the number of nodes in the pool. */ scaleSettings?: ScaleSettings; /** * @summary The results and errors from the last execution of the autoscale formula. * @description This property is set only if the pool automatically scales, i.e. * autoScaleSettings are used. */ readonly autoScaleRun?: AutoScaleRun; /** * @summary Whether the pool permits direct communication between nodes. * @description This imposes restrictions on which nodes can be assigned to the pool. Enabling * this value can reduce the chance of the requested number of nodes to be allocated in the pool. * If not specified, this value defaults to 'Disabled'. Possible values include: 'Enabled', * 'Disabled' */ interNodeCommunication?: string; /** * @summary The network configuration for the pool. */ networkConfiguration?: NetworkConfiguration; /** * @summary The maximum number of tasks that can run concurrently on a single compute node in the * pool. * @description The default value is 1. The maximum value is the smaller of 4 times the number of * cores of the vmSize of the pool or 256. */ maxTasksPerNode?: number; /** * @summary How tasks are distributed across compute nodes in a pool. * @description If not specified, the default is spread. */ taskSchedulingPolicy?: TaskSchedulingPolicy; /** * @summary The list of user accounts to be created on each node in the pool. */ userAccounts?: UserAccount[]; /** * @summary A list of name-value pairs associated with the pool as metadata. * @description The Batch service does not assign any meaning to metadata; it is solely for the * use of user code. */ metadata?: MetadataItem[]; /** * @summary A task specified to run on each compute node as it joins the pool. * @description In an PATCH (update) operation, this property can be set to an empty object to * remove the start task from the pool. */ startTask?: StartTask; /** * @summary The list of certificates to be installed on each compute node in the pool. * @description For Windows compute nodes, the Batch service installs the certificates to the * specified certificate store and location. For Linux compute nodes, the certificates are stored * in a directory inside the task working directory and an environment variable * AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For certificates * with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory * (e.g., /home/{user-name}/certs) and certificates are placed in that directory. */ certificates?: CertificateReference[]; /** * @summary The list of application packages to be installed on each compute node in the pool. * @description Changes to application package references affect all new compute nodes joining * the pool, but do not affect compute nodes that are already in the pool until they are rebooted * or reimaged. There is a maximum of 10 application package references on any given pool. */ applicationPackages?: ApplicationPackageReference[]; /** * @summary The list of application licenses the Batch service will make available on each * compute node in the pool. * @description The list of application licenses must be a subset of available Batch service * application licenses. If a license is requested which is not supported, pool creation will * fail. */ applicationLicenses?: string[]; /** * @summary Contains details about the current or last completed resize operation. */ readonly resizeOperationStatus?: ResizeOperationStatus; /** * @summary A list of file systems to mount on each node in the pool. * @description This supports Azure Files, NFS, CIFS/SMB, and Blobfuse. */ mountConfiguration?: MountConfiguration[]; } /** * @summary The object that describes the operation. */ export interface OperationDisplay { /** * @summary Friendly name of the resource provider. */ provider?: string; /** * @summary The operation type. * @description For example: read, write, delete, or listKeys/action */ operation?: string; /** * @summary The resource type on which the operation is performed. */ resource?: string; /** * @summary The friendly name of the operation */ description?: string; } /** * @summary A REST API operation */ export interface Operation { /** * @summary The operation name. * @description This is of the format {provider}/{resource}/{operation} */ name?: string; /** * @summary The object that describes the operation. */ display?: OperationDisplay; /** * @summary The intended executor of the operation. */ origin?: string; /** * @summary Properties of the operation. */ properties?: any; } /** * Parameters for a check name availability request. */ export interface CheckNameAvailabilityParameters { /** * The name to check for availability */ name: string; } /** * The CheckNameAvailability operation response. */ export interface CheckNameAvailabilityResult { /** * Gets a boolean value that indicates whether the name is available for you to use. If true, the * name is available. If false, the name has already been taken or invalid and cannot be used. */ readonly nameAvailable?: boolean; /** * Gets the reason that a Batch account name could not be used. The Reason element is only * returned if NameAvailable is false. Possible values include: 'Invalid', 'AlreadyExists' */ readonly reason?: string; /** * Gets an error message explaining the Reason value in more detail. */ readonly message?: string; } /** * Values returned by the List operation. */ export interface BatchAccountListResult extends Array { /** * The continuation token. */ nextLink?: string; } /** * The result of performing list application packages. */ export interface ListApplicationPackagesResult extends Array { /** * The URL to get the next set of results. */ nextLink?: string; } /** * The result of performing list applications. */ export interface ListApplicationsResult extends Array { /** * The URL to get the next set of results. */ nextLink?: string; } /** * @summary Result of the request to list REST API operations. It contains a list of operations and * a URL nextLink to get the next set of results. */ export interface OperationListResult extends Array { /** * @summary The URL to get the next set of operation list results if there are any. */ nextLink?: string; } /** * Values returned by the List operation. */ export interface ListCertificatesResult extends Array { /** * The continuation token. */ nextLink?: string; } /** * Values returned by the List operation. */ export interface ListPrivateLinkResourcesResult extends Array { /** * The continuation token. */ nextLink?: string; } /** * Values returned by the List operation. */ export interface ListPrivateEndpointConnectionsResult extends Array { /** * The continuation token. */ nextLink?: string; } /** * Values returned by the List operation. */ export interface ListPoolsResult extends Array { /** * The continuation token. */ nextLink?: string; }