From 188f57a01b72597c176e1d6e1cf3d81c39542482 Mon Sep 17 00:00:00 2001 From: vimalcha <70863599+vimalcha@users.noreply.github.com> Date: Sat, 23 Mar 2024 06:30:16 +0530 Subject: [PATCH] Mnva network profile support and minor fixes (#28291) * Added support for network profile * Fixed typos and changed name of definitions * Ran npx prettier * Added x-ms-enum and few more descriptions * Added x-ms-client-name * Added x-ms-identifier and shorten the names --- .../examples/NetworkVirtualApplianceGet.json | 83 +++++++-- ...rkVirtualApplianceListByResourceGroup.json | 87 ++++++++- ...orkVirtualApplianceListBySubscription.json | 87 ++++++++- .../examples/NetworkVirtualAppliancePut.json | 171 +++++++++++++++++- .../2023-11-01/networkVirtualAppliance.json | 90 +++++++++ 5 files changed, 495 insertions(+), 23 deletions(-) diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceGet.json b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceGet.json index fce78fab24d0..4695602b9047 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceGet.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceGet.json @@ -55,36 +55,95 @@ "https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrcloudinitconfig" ], "virtualApplianceAsn": 10000, + "additionalNics": [ + { + "name": "exrsdwan", + "hasPublicIp": true + } + ], + "internetIngressPublicIps": [ + { + "id": "/subscriptions/{{subscriptionId}}/resourceGroups/{{rg}}/providers/Microsoft.Network/publicIPAddresses/slbip" + } + ], + "networkProfile": { + "networkInterfaceConfigurations": [ + { + "type": "PublicNic", + "properties": { + "ipConfigurations": [ + { + "name": "publicnicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "publicnicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + }, + { + "type": "PrivateNic", + "properties": { + "ipConfigurations": [ + { + "name": "privatenicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "privatenicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + } + ] + }, "virtualApplianceNics": [ { + "nicType": "PublicNic", "name": "publicnicipconfig", "publicIpAddress": "40.30.2.2", "privateIpAddress": "192.168.12.1", "instanceName": "nva_0" }, { + "nicType": "PublicNic", + "name": "publicnicipconfig-2", + "publicIpAddress": "40.30.2.3", + "privateIpAddress": "192.168.12.2", + "instanceName": "nva_0" + }, + { + "nicType": "PrivateNic", "name": "privatenicipconfig", "publicIpAddress": "", - "privateIpAddress": "192.168.12.2", + "privateIpAddress": "192.168.12.3", + "instanceName": "nva_0" + }, + { + "nicType": "PrivateNic", + "name": "privatenicipconfig-2", + "publicIpAddress": "", + "privateIpAddress": "192.168.12.4", "instanceName": "nva_0" }, { + "nicType": "AdditionalNic", "name": "exrsdwan", "publicIpAddress": "4.231.25.19", "privateIpAddress": "10.1.113.4", "instanceName": "nva_0" } - ], - "additionalNics": [ - { - "name": "exrsdwan", - "hasPublicIp": true - } - ], - "internetIngressPublicIps": [ - { - "id": "/subscriptions/{{subscriptionId}}/resourceGroups/{{rg}}/providers/Microsoft.Network/publicIPAddresses/slbip" - } ] } } diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceListByResourceGroup.json b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceListByResourceGroup.json index c6a43651d627..d8589d582309 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceListByResourceGroup.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceListByResourceGroup.json @@ -51,15 +51,94 @@ "https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrcloudinitconfig" ], "virtualApplianceAsn": 10000, + "additionalNics": [ + { + "name": "exrsdwan", + "hasPublicIp": true + } + ], + "internetIngressPublicIps": [ + { + "id": "/subscriptions/{{subscriptionId}}/resourceGroups/{{rg}}/providers/Microsoft.Network/publicIPAddresses/slbip" + } + ], + "networkProfile": { + "networkInterfaceConfigurations": [ + { + "type": "PublicNic", + "properties": { + "ipConfigurations": [ + { + "name": "publicnicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "publicnicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + }, + { + "type": "PrivateNic", + "properties": { + "ipConfigurations": [ + { + "name": "privatenicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "privatenicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + } + ] + }, "virtualApplianceNics": [ { - "name": "managementNic", + "nicType": "PublicNic", + "name": "publicnicipconfig", "publicIpAddress": "40.30.2.2", - "privateIpAddress": "192.168.12.1" + "privateIpAddress": "192.168.12.1", + "instanceName": "nva_0" + }, + { + "nicType": "PublicNic", + "name": "publicnicipconfig-2", + "publicIpAddress": "40.30.2.3", + "privateIpAddress": "192.168.12.2", + "instanceName": "nva_0" + }, + { + "nicType": "PrivateNic", + "name": "privatenicipconfig", + "publicIpAddress": "", + "privateIpAddress": "192.168.12.3", + "instanceName": "nva_0" + }, + { + "nicType": "PrivateNic", + "name": "privatenicipconfig-2", + "publicIpAddress": "", + "privateIpAddress": "192.168.12.4", + "instanceName": "nva_0" }, { - "name": "privateNic-1", - "privateIpAddress": "192.168.12.2" + "nicType": "AdditionalNic", + "name": "exrsdwan", + "publicIpAddress": "4.231.25.19", + "privateIpAddress": "10.1.113.4", + "instanceName": "nva_0" } ] } diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceListBySubscription.json b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceListBySubscription.json index 7cf774dea244..2523d7fc648d 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceListBySubscription.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualApplianceListBySubscription.json @@ -50,15 +50,94 @@ "https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrcloudinitconfig" ], "virtualApplianceAsn": 10000, + "additionalNics": [ + { + "name": "exrsdwan", + "hasPublicIp": true + } + ], + "internetIngressPublicIps": [ + { + "id": "/subscriptions/{{subscriptionId}}/resourceGroups/{{rg}}/providers/Microsoft.Network/publicIPAddresses/slbip" + } + ], + "networkProfile": { + "networkInterfaceConfigurations": [ + { + "type": "PublicNic", + "properties": { + "ipConfigurations": [ + { + "name": "publicnicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "publicnicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + }, + { + "type": "PrivateNic", + "properties": { + "ipConfigurations": [ + { + "name": "privatenicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "privatenicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + } + ] + }, "virtualApplianceNics": [ { - "name": "managementNic", + "nicType": "PublicNic", + "name": "publicnicipconfig", "publicIpAddress": "40.30.2.2", - "privateIpAddress": "192.168.12.1" + "privateIpAddress": "192.168.12.1", + "instanceName": "nva_0" + }, + { + "nicType": "PublicNic", + "name": "publicnicipconfig-2", + "publicIpAddress": "40.30.2.3", + "privateIpAddress": "192.168.12.2", + "instanceName": "nva_0" + }, + { + "nicType": "PrivateNic", + "name": "privatenicipconfig", + "publicIpAddress": "", + "privateIpAddress": "192.168.12.3", + "instanceName": "nva_0" + }, + { + "nicType": "PrivateNic", + "name": "privatenicipconfig-2", + "publicIpAddress": "", + "privateIpAddress": "192.168.12.4", + "instanceName": "nva_0" }, { - "name": "privateNic-1", - "privateIpAddress": "192.168.12.2" + "nicType": "AdditionalNic", + "name": "exrsdwan", + "publicIpAddress": "4.231.25.19", + "privateIpAddress": "10.1.113.4", + "instanceName": "nva_0" } ] } diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualAppliancePut.json b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualAppliancePut.json index a0dd0aabe9c2..4d5fd9f0f3a2 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualAppliancePut.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/examples/NetworkVirtualAppliancePut.json @@ -41,7 +41,49 @@ { "id": "/subscriptions/{{subscriptionId}}/resourceGroups/{{rg}}/providers/Microsoft.Network/publicIPAddresses/slbip" } - ] + ], + "networkProfile": { + "networkInterfaceConfigurations": [ + { + "type": "PublicNic", + "properties": { + "ipConfigurations": [ + { + "name": "publicnicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "publicnicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + }, + { + "type": "PrivateNic", + "properties": { + "ipConfigurations": [ + { + "name": "privatenicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "privatenicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + } + ] + } } } }, @@ -90,20 +132,90 @@ "https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrcloudinitconfig" ], "virtualApplianceAsn": 10000, + "additionalNics": [ + { + "name": "exrsdwan", + "hasPublicIp": true + } + ], + "internetIngressPublicIps": [ + { + "id": "/subscriptions/{{subscriptionId}}/resourceGroups/{{rg}}/providers/Microsoft.Network/publicIPAddresses/slbip" + } + ], + "networkProfile": { + "networkInterfaceConfigurations": [ + { + "type": "PublicNic", + "properties": { + "ipConfigurations": [ + { + "name": "publicnicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "publicnicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + }, + { + "type": "PrivateNic", + "properties": { + "ipConfigurations": [ + { + "name": "privatenicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "privatenicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + } + ] + }, "virtualApplianceNics": [ { + "nicType": "PublicNic", "name": "publicnicipconfig", "publicIpAddress": "40.30.2.2", "privateIpAddress": "192.168.12.1", "instanceName": "nva_0" }, { + "nicType": "PublicNic", + "name": "publicnicipconfig-2", + "publicIpAddress": "40.30.2.3", + "privateIpAddress": "192.168.12.2", + "instanceName": "nva_0" + }, + { + "nicType": "PrivateNic", "name": "privatenicipconfig", "publicIpAddress": "", - "privateIpAddress": "192.168.12.2", + "privateIpAddress": "192.168.12.3", + "instanceName": "nva_0" + }, + { + "nicType": "PrivateNic", + "name": "privatenicipconfig-2", + "publicIpAddress": "", + "privateIpAddress": "192.168.12.4", "instanceName": "nva_0" }, { + "nicType": "AdditionalNic", "name": "exrsdwan", "publicIpAddress": "4.231.25.19", "privateIpAddress": "10.1.113.4", @@ -159,7 +271,60 @@ "cloudInitConfigurationBlobs": [ "https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrcloudinitconfig" ], - "virtualApplianceAsn": 10000 + "virtualApplianceAsn": 10000, + "additionalNics": [ + { + "name": "exrsdwan", + "hasPublicIp": true + } + ], + "internetIngressPublicIps": [ + { + "id": "/subscriptions/{{subscriptionId}}/resourceGroups/{{rg}}/providers/Microsoft.Network/publicIPAddresses/slbip" + } + ], + "networkProfile": { + "networkInterfaceConfigurations": [ + { + "type": "PublicNic", + "properties": { + "ipConfigurations": [ + { + "name": "publicnicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "publicnicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + }, + { + "type": "PrivateNic", + "properties": { + "ipConfigurations": [ + { + "name": "privatenicipconfig", + "properties": { + "primary": true + } + }, + { + "name": "privatenicipconfig-2", + "properties": { + "primary": false + } + } + ] + } + } + ] + } } } } diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/networkVirtualAppliance.json b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/networkVirtualAppliance.json index 8d13076d5162..fa525a27c8f9 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/networkVirtualAppliance.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/networkVirtualAppliance.json @@ -915,6 +915,20 @@ "$ref": "#/definitions/VirtualApplianceNicProperties" } }, + "networkProfile": { + "type": "object", + "readOnly": false, + "description": "Network Profile containing configurations for Public and Private NIC.", + "properties": { + "networkInterfaceConfigurations": { + "type": "array", + "items": { + "$ref": "#/definitions/VirtualApplianceNetworkInterfaceConfiguration" + }, + "x-ms-identifiers": [] + } + } + }, "additionalNics": { "type": "array", "readOnly": false, @@ -1000,6 +1014,20 @@ }, "VirtualApplianceNicProperties": { "properties": { + "nicType": { + "type": "string", + "readOnly": true, + "description": "NIC type - PublicNic, PrivateNic, or AdditionalNic.", + "enum": [ + "PublicNic", + "PrivateNic", + "AdditionalNic" + ], + "x-ms-enum": { + "name": "NicTypeInResponse", + "modelAsString": true + } + }, "name": { "type": "string", "readOnly": true, @@ -1023,6 +1051,68 @@ }, "description": "Network Virtual Appliance NIC properties." }, + "VirtualApplianceNetworkInterfaceConfiguration": { + "type": "object", + "readOnly": false, + "description": "Represents a single NIC configuration.", + "properties": { + "type": { + "type": "string", + "description": "NIC type. This should be either PublicNic or PrivateNic.", + "enum": [ + "PublicNic", + "PrivateNic" + ], + "x-ms-enum": { + "name": "NicTypeInRequest", + "modelAsString": true + }, + "x-ms-client-name": "NicType" + }, + "properties": { + "$ref": "#/definitions/VirtualApplianceNetworkInterfaceConfigurationProperties" + } + } + }, + "VirtualApplianceNetworkInterfaceConfigurationProperties": { + "type": "object", + "readOnly": false, + "description": "Represents a single NIC configuration properties.", + "properties": { + "ipConfigurations": { + "type": "array", + "items": { + "$ref": "#/definitions/VirtualApplianceIPConfiguration" + }, + "x-ms-identifiers": [] + } + } + }, + "VirtualApplianceIPConfiguration": { + "type": "object", + "readOnly": false, + "description": "Represents a single IP configuration.", + "properties": { + "name": { + "type": "string", + "description": "Name of the IP configuration." + }, + "properties": { + "$ref": "#/definitions/VirtualApplianceIPConfigurationProperties" + } + } + }, + "VirtualApplianceIPConfigurationProperties": { + "type": "object", + "readOnly": false, + "description": "Represents a single IP configuration properties.", + "properties": { + "primary": { + "type": "boolean", + "description": "Whether or not this is primary IP configuration of the NIC." + } + } + }, "VirtualApplianceAdditionalNicProperties": { "type": "object", "title": "Network Virtual Appliance Additional Nic Properties",