| | 1 | | // <auto-generated> |
| | 2 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 3 | | // Licensed under the MIT License. See License.txt in the project root for |
| | 4 | | // license information. |
| | 5 | | // |
| | 6 | | // Code generated by Microsoft (R) AutoRest Code Generator. |
| | 7 | | // Changes may cause incorrect behavior and will be lost if the code is |
| | 8 | | // regenerated. |
| | 9 | | // </auto-generated> |
| | 10 | |
|
| | 11 | | namespace Microsoft.Azure.Batch.Protocol.Models |
| | 12 | | { |
| | 13 | | using Newtonsoft.Json; |
| | 14 | | using System.Linq; |
| | 15 | |
|
| | 16 | | /// <summary> |
| | 17 | | /// The network configuration for a Pool. |
| | 18 | | /// </summary> |
| | 19 | | public partial class NetworkConfiguration |
| | 20 | | { |
| | 21 | | /// <summary> |
| | 22 | | /// Initializes a new instance of the NetworkConfiguration class. |
| | 23 | | /// </summary> |
| 834 | 24 | | public NetworkConfiguration() |
| | 25 | | { |
| | 26 | | CustomInit(); |
| 834 | 27 | | } |
| | 28 | |
|
| | 29 | | /// <summary> |
| | 30 | | /// Initializes a new instance of the NetworkConfiguration class. |
| | 31 | | /// </summary> |
| | 32 | | /// <param name="subnetId">The ARM resource identifier of the virtual |
| | 33 | | /// network subnet which the Compute Nodes of the Pool will join. This |
| | 34 | | /// is of the form |
| | 35 | | /// /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/ |
| | 36 | | /// <param name="dynamicVNetAssignmentScope">The scope of dynamic vnet |
| | 37 | | /// assignment.</param> |
| | 38 | | /// <param name="endpointConfiguration">The configuration for endpoints |
| | 39 | | /// on Compute Nodes in the Batch Pool.</param> |
| | 40 | | /// <param name="publicIPAddressConfiguration">The Public IPAddress |
| | 41 | | /// configuration for Compute Nodes in the Batch Pool.</param> |
| 0 | 42 | | public NetworkConfiguration(string subnetId = default(string), DynamicVNetAssignmentScope? dynamicVNetAssignment |
| | 43 | | { |
| 0 | 44 | | SubnetId = subnetId; |
| 0 | 45 | | DynamicVNetAssignmentScope = dynamicVNetAssignmentScope; |
| 0 | 46 | | EndpointConfiguration = endpointConfiguration; |
| 0 | 47 | | PublicIPAddressConfiguration = publicIPAddressConfiguration; |
| | 48 | | CustomInit(); |
| 0 | 49 | | } |
| | 50 | |
|
| | 51 | | /// <summary> |
| | 52 | | /// An initialization method that performs custom operations like setting defaults |
| | 53 | | /// </summary> |
| | 54 | | partial void CustomInit(); |
| | 55 | |
|
| | 56 | | /// <summary> |
| | 57 | | /// Gets or sets the ARM resource identifier of the virtual network |
| | 58 | | /// subnet which the Compute Nodes of the Pool will join. This is of |
| | 59 | | /// the form |
| | 60 | | /// /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/ |
| | 61 | | /// </summary> |
| | 62 | | /// <remarks> |
| | 63 | | /// The virtual network must be in the same region and subscription as |
| | 64 | | /// the Azure Batch Account. The specified subnet should have enough |
| | 65 | | /// free IP addresses to accommodate the number of Compute Nodes in the |
| | 66 | | /// Pool. If the subnet doesn't have enough free IP addresses, the Pool |
| | 67 | | /// will partially allocate Nodes and a resize error will occur. The |
| | 68 | | /// 'MicrosoftAzureBatch' service principal must have the 'Classic |
| | 69 | | /// Virtual Machine Contributor' Role-Based Access Control (RBAC) role |
| | 70 | | /// for the specified VNet. The specified subnet must allow |
| | 71 | | /// communication from the Azure Batch service to be able to schedule |
| | 72 | | /// Tasks on the Nodes. This can be verified by checking if the |
| | 73 | | /// specified VNet has any associated Network Security Groups (NSG). If |
| | 74 | | /// communication to the Nodes in the specified subnet is denied by an |
| | 75 | | /// NSG, then the Batch service will set the state of the Compute Nodes |
| | 76 | | /// to unusable. For Pools created with virtualMachineConfiguration |
| | 77 | | /// only ARM virtual networks ('Microsoft.Network/virtualNetworks') are |
| | 78 | | /// supported, but for Pools created with cloudServiceConfiguration |
| | 79 | | /// both ARM and classic virtual networks are supported. If the |
| | 80 | | /// specified VNet has any associated Network Security Groups (NSG), |
| | 81 | | /// then a few reserved system ports must be enabled for inbound |
| | 82 | | /// communication. For Pools created with a virtual machine |
| | 83 | | /// configuration, enable ports 29876 and 29877, as well as port 22 for |
| | 84 | | /// Linux and port 3389 for Windows. For Pools created with a cloud |
| | 85 | | /// service configuration, enable ports 10100, 20100, and 30100. Also |
| | 86 | | /// enable outbound connections to Azure Storage on port 443. For more |
| | 87 | | /// details see: |
| | 88 | | /// https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuratio |
| | 89 | | /// </remarks> |
| | 90 | | [JsonProperty(PropertyName = "subnetId")] |
| 1975 | 91 | | public string SubnetId { get; set; } |
| | 92 | |
|
| | 93 | | /// <summary> |
| | 94 | | /// Gets or sets the scope of dynamic vnet assignment. |
| | 95 | | /// </summary> |
| | 96 | | /// <remarks> |
| | 97 | | /// Possible values include: 'none', 'job' |
| | 98 | | /// </remarks> |
| | 99 | | [JsonProperty(PropertyName = "dynamicVNetAssignmentScope")] |
| 1976 | 100 | | public DynamicVNetAssignmentScope? DynamicVNetAssignmentScope { get; set; } |
| | 101 | |
|
| | 102 | | /// <summary> |
| | 103 | | /// Gets or sets the configuration for endpoints on Compute Nodes in |
| | 104 | | /// the Batch Pool. |
| | 105 | | /// </summary> |
| | 106 | | /// <remarks> |
| | 107 | | /// Pool endpoint configuration is only supported on Pools with the |
| | 108 | | /// virtualMachineConfiguration property. |
| | 109 | | /// </remarks> |
| | 110 | | [JsonProperty(PropertyName = "endpointConfiguration")] |
| 1963 | 111 | | public PoolEndpointConfiguration EndpointConfiguration { get; set; } |
| | 112 | |
|
| | 113 | | /// <summary> |
| | 114 | | /// Gets or sets the Public IPAddress configuration for Compute Nodes |
| | 115 | | /// in the Batch Pool. |
| | 116 | | /// </summary> |
| | 117 | | /// <remarks> |
| | 118 | | /// Public IP configuration property is only supported on Pools with |
| | 119 | | /// the virtualMachineConfiguration property. |
| | 120 | | /// </remarks> |
| | 121 | | [JsonProperty(PropertyName = "publicIPAddressConfiguration")] |
| 1990 | 122 | | public PublicIPAddressConfiguration PublicIPAddressConfiguration { get; set; } |
| | 123 | |
|
| | 124 | | } |
| | 125 | | } |