Skip to content

Commit 2dfe4ad

Browse files
azure-pipelines[bot]azure-powershell-botvidai-msft
authored
Migrate ConnectedMachine from generation to main (#26657)
* Move ConnectedMachine to main * Update ChangeLog.md * Fix signature issues. --------- Co-authored-by: azure-powershell-bot <[email protected]> Co-authored-by: Vincent Dai <[email protected]>
1 parent 174cc61 commit 2dfe4ad

File tree

418 files changed

+79112
-9945
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

418 files changed

+79112
-9945
lines changed

src/ConnectedMachine/ConnectedMachine.Autorest/Az.ConnectedMachine.format.ps1xml

Lines changed: 1158 additions & 48 deletions
Large diffs are not rendered by default.

src/ConnectedMachine/ConnectedMachine.Autorest/Az.ConnectedMachine.psd1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
DotNetFrameworkVersion = '4.7.2'
1212
RequiredAssemblies = './bin/Az.ConnectedMachine.private.dll'
1313
FormatsToProcess = './Az.ConnectedMachine.format.ps1xml'
14-
FunctionsToExport = 'Connect-AzConnectedMachine', 'Get-AzConnectedExtensionMetadata', 'Get-AzConnectedLicense', 'Get-AzConnectedMachine', 'Get-AzConnectedMachineExtension', 'Get-AzConnectedNetworkSecurityPerimeterConfiguration', 'Get-AzConnectedPrivateLinkScope', 'Install-AzConnectedMachinePatch', 'Invoke-AzConnectedAssessMachinePatch', 'Invoke-AzConnectedReconcileNetworkSecurityPerimeterConfiguration', 'New-AzConnectedLicense', 'New-AzConnectedLicenseDetail', 'New-AzConnectedMachineExtension', 'New-AzConnectedPrivateLinkScope', 'Remove-AzConnectedLicense', 'Remove-AzConnectedMachine', 'Remove-AzConnectedMachineExtension', 'Remove-AzConnectedPrivateLinkScope', 'Set-AzConnectedLicense', 'Set-AzConnectedMachineExtension', 'Set-AzConnectedPrivateLinkScope', 'Update-AzConnectedExtension', 'Update-AzConnectedMachine', 'Update-AzConnectedMachineExtension', 'Update-AzConnectedPrivateLinkScopeTag'
14+
FunctionsToExport = 'Connect-AzConnectedMachine', 'Get-AzConnectedExtensionMetadata', 'Get-AzConnectedLicense', 'Get-AzConnectedLicenseProfile', 'Get-AzConnectedMachine', 'Get-AzConnectedMachineExtension', 'Get-AzConnectedMachineRunCommand', 'Get-AzConnectedNetworkSecurityPerimeterConfiguration', 'Get-AzConnectedPrivateLinkScope', 'Install-AzConnectedMachinePatch', 'Invoke-AzConnectedAssessMachinePatch', 'Invoke-AzConnectedReconcileNetworkSecurityPerimeterConfiguration', 'New-AzConnectedLicense', 'New-AzConnectedLicenseDetail', 'New-AzConnectedLicenseProfile', 'New-AzConnectedLicenseProfileFeature', 'New-AzConnectedMachineExtension', 'New-AzConnectedMachineRunCommand', 'New-AzConnectedPrivateLinkScope', 'Remove-AzConnectedLicense', 'Remove-AzConnectedLicenseProfile', 'Remove-AzConnectedMachine', 'Remove-AzConnectedMachineExtension', 'Remove-AzConnectedMachineRunCommand', 'Remove-AzConnectedPrivateLinkScope', 'Set-AzConnectedLicense', 'Set-AzConnectedMachineExtension', 'Set-AzConnectedPrivateLinkScope', 'Update-AzConnectedExtension', 'Update-AzConnectedLicenseProfile', 'Update-AzConnectedLicenseProfileFeature', 'Update-AzConnectedMachine', 'Update-AzConnectedMachineExtension', 'Update-AzConnectedMachineRunCommand', 'Update-AzConnectedPrivateLinkScopeTag'
1515
PrivateData = @{
1616
PSData = @{
1717
Tags = 'Azure', 'ResourceManager', 'ARM', 'PSModule', 'ConnectedMachine'

src/ConnectedMachine/ConnectedMachine.Autorest/README.md

Lines changed: 65 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -38,12 +38,12 @@ In this directory, run AutoRest:
3838
> see https://aka.ms/autorest
3939
4040
``` yaml
41-
commit: f41d0c9332078cb2ef07b749081d94915255ada5
41+
commit: a9980ec5181a161dd26c5277f7651722b60503ea
4242
require:
4343
- $(this-folder)/../../readme.azure.noprofile.md
4444
input-file:
45-
- $(repo)/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/HybridCompute.json
46-
- $(repo)/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/privateLinkScopes.json
45+
- $(repo)/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/preview/2024-07-31-preview/HybridCompute.json
46+
- $(repo)/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/preview/2024-07-31-preview/privateLinkScopes.json
4747

4848
module-version: 0.1.0
4949
title: ConnectedMachine
@@ -176,41 +176,41 @@ directive:
176176
}
177177
178178
# add 200 response to run-command delete - comment out for stable release
179-
# - from: swagger-document
180-
# where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/runCommands/{runCommandName}"].delete.responses
181-
# transform: >-
182-
# return {
183-
# "200": {
184-
# "description": "OK"
185-
# },
186-
# "202": {
187-
# "description": "Accepted",
188-
# "headers": {
189-
# "Location": {
190-
# "description": "The URL of the resource used to check the status of the asynchronous operation.",
191-
# "type": "string"
192-
# },
193-
# "Retry-After": {
194-
# "description": "The recommended number of seconds to wait before calling the URI specified in Azure-AsyncOperation.",
195-
# "type": "integer",
196-
# "format": "int32"
197-
# },
198-
# "Azure-AsyncOperation": {
199-
# "description": "The URI to poll for completion status.",
200-
# "type": "string"
201-
# }
202-
# }
203-
# },
204-
# "204": {
205-
# "description": "No Content"
206-
# },
207-
# "default": {
208-
# "description": "Error response describing why the operation failed.",
209-
# "schema": {
210-
# "$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ErrorResponse"
211-
# }
212-
# }
213-
# }
179+
- from: swagger-document
180+
where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/runCommands/{runCommandName}"].delete.responses
181+
transform: >-
182+
return {
183+
"200": {
184+
"description": "OK"
185+
},
186+
"202": {
187+
"description": "Accepted",
188+
"headers": {
189+
"Location": {
190+
"description": "The URL of the resource used to check the status of the asynchronous operation.",
191+
"type": "string"
192+
},
193+
"Retry-After": {
194+
"description": "The recommended number of seconds to wait before calling the URI specified in Azure-AsyncOperation.",
195+
"type": "integer",
196+
"format": "int32"
197+
},
198+
"Azure-AsyncOperation": {
199+
"description": "The URI to poll for completion status.",
200+
"type": "string"
201+
}
202+
}
203+
},
204+
"204": {
205+
"description": "No Content"
206+
},
207+
"default": {
208+
"description": "Error response describing why the operation failed.",
209+
"schema": {
210+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ErrorResponse"
211+
}
212+
}
213+
}
214214
215215
# GetViaIdentity isn't useful until Azure PowerShell supports piping of different subjects
216216
- where:
@@ -259,6 +259,11 @@ directive:
259259
parameter-name: AgentUpgradeEnableAutomaticUpgrade
260260
set:
261261
parameter-name: AgentUpgradeEnableAutomatic
262+
- where:
263+
subject: MachineRunCommand
264+
parameter-name: SubscriptionId
265+
set:
266+
alias: Subscription
262267

263268
# Rename Tag to Tags
264269
- where:
@@ -324,23 +329,18 @@ directive:
324329
subject: MachineRunCommand
325330
verb: Set
326331
remove: true
327-
# internal API
328-
- where:
329-
subject: LicenseProfile
330-
remove: true
331332
- where:
332333
subject: Extension
333334
variant: Upgrade
334335
remove: true
335336

336-
# we will release gateway and setting commands in a seperate module - comment out for stable release
337-
# - where:
338-
# subject: Gateway
339-
# remove: true
340-
# Remove when this API version is added - comment out for stable release
341-
# - where:
342-
# subject: Setting
343-
# remove: true
337+
# we will release gateway and setting commands in a seperate module
338+
- where:
339+
subject: Gateway
340+
remove: true
341+
- where:
342+
subject: Setting
343+
remove: true
344344

345345
# We don't want user to send PATCH to the ESU license API
346346
- where:
@@ -356,6 +356,12 @@ directive:
356356
verb: Test
357357
remove: true
358358

359+
# hide Set-AzConnectedLicenseProfile (PUT) from user and keep Update-AzConnectedLicenseProfile (PATCH)
360+
- where:
361+
subject: LicenseProfile
362+
verb: Set
363+
remove: true
364+
359365
# We don't want user to talk directly to the network configuration API
360366
- where:
361367
subject: NetworkConfiguration
@@ -392,5 +398,14 @@ directive:
392398
- model-cmdlet:
393399
- model-name: LicenseDetails
394400
cmdlet-name: New-AzConnectedLicenseDetail
401+
402+
# Generate complex object for Update-AzConnectedLicenseProfile
403+
- model-cmdlet:
404+
- model-name: ProductFeatureUpdate
405+
cmdlet-name: Update-AzConnectedLicenseProfileFeature
406+
# Generate complex object for New-AzConnectedLicenseProfile, change prefix to New- will cause CI styling issue
407+
- model-cmdlet:
408+
- model-name: ProductFeature
409+
cmdlet-name: New-AzConnectedLicenseProfileFeature
395410

396411
```

src/ConnectedMachine/ConnectedMachine.Autorest/UX/Microsoft.HybridCompute/licenses.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"resourceType": "licenses",
3-
"apiVersion": "2024-07-10",
3+
"apiVersion": "2024-07-31-preview",
44
"learnMore": {
55
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
66
},

src/ConnectedMachine/ConnectedMachine.Autorest/UX/Microsoft.HybridCompute/locations-publishers-extensionTypes-versions.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"resourceType": "locations/publishers/extensionTypes/versions",
3-
"apiVersion": "2024-07-10",
3+
"apiVersion": "2024-07-31-preview",
44
"learnMore": {
55
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
66
},

src/ConnectedMachine/ConnectedMachine.Autorest/UX/Microsoft.HybridCompute/machines-extensions.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"resourceType": "machines/extensions",
3-
"apiVersion": "2024-07-10",
3+
"apiVersion": "2024-07-31-preview",
44
"learnMore": {
55
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
66
},
Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
{
2+
"resourceType": "machines/licenseProfiles",
3+
"apiVersion": "2024-07-31-preview",
4+
"learnMore": {
5+
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
6+
},
7+
"commands": [
8+
{
9+
"name": "Get-AzConnectedLicenseProfile",
10+
"description": "Retrieves information about the view of a license profile.",
11+
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/licenseProfiles/{licenseProfileName}",
12+
"help": {
13+
"learnMore": {
14+
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine/get-azconnectedlicenseprofile"
15+
},
16+
"parameterSets": [
17+
{
18+
"parameters": [
19+
"-MachineName <String>",
20+
"-ResourceGroupName <String>",
21+
"[-SubscriptionId <String[]>]"
22+
]
23+
}
24+
]
25+
},
26+
"examples": [
27+
{
28+
"description": "Retrieves information about the view of a license profile.",
29+
"parameters": [
30+
{
31+
"name": "-MachineName",
32+
"value": "[Path.machineName]"
33+
},
34+
{
35+
"name": "-ResourceGroupName",
36+
"value": "[Path.resourceGroupName]"
37+
},
38+
{
39+
"name": "-SubscriptionId",
40+
"value": "[Path.subscriptionId]"
41+
}
42+
]
43+
}
44+
]
45+
},
46+
{
47+
"name": "Remove-AzConnectedLicenseProfile",
48+
"description": "The operation to delete a license profile.",
49+
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/licenseProfiles/{licenseProfileName}",
50+
"help": {
51+
"learnMore": {
52+
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine/remove-azconnectedlicenseprofile"
53+
},
54+
"parameterSets": [
55+
{
56+
"parameters": [
57+
"-MachineName <String>",
58+
"-ResourceGroupName <String>",
59+
"[-SubscriptionId <String>]"
60+
]
61+
}
62+
]
63+
},
64+
"examples": [
65+
{
66+
"description": "The operation to delete a license profile.",
67+
"parameters": [
68+
{
69+
"name": "-MachineName",
70+
"value": "[Path.machineName]"
71+
},
72+
{
73+
"name": "-ResourceGroupName",
74+
"value": "[Path.resourceGroupName]"
75+
},
76+
{
77+
"name": "-SubscriptionId",
78+
"value": "[Path.subscriptionId]"
79+
}
80+
]
81+
}
82+
]
83+
}
84+
]
85+
}
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
{
2+
"resourceType": "machines/runCommands",
3+
"apiVersion": "2024-07-31-preview",
4+
"learnMore": {
5+
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
6+
},
7+
"commands": [
8+
{
9+
"name": "Get-AzConnectedMachineRunCommand",
10+
"description": "The operation to get a run command.",
11+
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/runCommands/{runCommandName}",
12+
"help": {
13+
"learnMore": {
14+
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine/get-azconnectedmachineruncommand"
15+
},
16+
"parameterSets": [
17+
{
18+
"parameters": [
19+
"-MachineName <String>",
20+
"-ResourceGroupName <String>",
21+
"-RunCommandName <String>",
22+
"[-SubscriptionId <String[]>]"
23+
]
24+
}
25+
]
26+
},
27+
"examples": [
28+
{
29+
"description": "The operation to get a run command.",
30+
"parameters": [
31+
{
32+
"name": "-MachineName",
33+
"value": "[Path.machineName]"
34+
},
35+
{
36+
"name": "-ResourceGroupName",
37+
"value": "[Path.resourceGroupName]"
38+
},
39+
{
40+
"name": "-RunCommandName",
41+
"value": "[Path.runCommandName]"
42+
},
43+
{
44+
"name": "-SubscriptionId",
45+
"value": "[Path.subscriptionId]"
46+
}
47+
]
48+
}
49+
]
50+
},
51+
{
52+
"name": "Remove-AzConnectedMachineRunCommand",
53+
"description": "The operation to delete a run command.",
54+
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/runCommands/{runCommandName}",
55+
"help": {
56+
"learnMore": {
57+
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine/remove-azconnectedmachineruncommand"
58+
},
59+
"parameterSets": [
60+
{
61+
"parameters": [
62+
"-MachineName <String>",
63+
"-ResourceGroupName <String>",
64+
"-RunCommandName <String>",
65+
"[-SubscriptionId <String>]"
66+
]
67+
}
68+
]
69+
},
70+
"examples": [
71+
{
72+
"description": "The operation to delete a run command.",
73+
"parameters": [
74+
{
75+
"name": "-MachineName",
76+
"value": "[Path.machineName]"
77+
},
78+
{
79+
"name": "-ResourceGroupName",
80+
"value": "[Path.resourceGroupName]"
81+
},
82+
{
83+
"name": "-RunCommandName",
84+
"value": "[Path.runCommandName]"
85+
},
86+
{
87+
"name": "-SubscriptionId",
88+
"value": "[Path.subscriptionId]"
89+
}
90+
]
91+
}
92+
]
93+
}
94+
]
95+
}

src/ConnectedMachine/ConnectedMachine.Autorest/UX/Microsoft.HybridCompute/machines.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"resourceType": "machines",
3-
"apiVersion": "2024-07-10",
3+
"apiVersion": "2024-07-31-preview",
44
"learnMore": {
55
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
66
},

src/ConnectedMachine/ConnectedMachine.Autorest/UX/Microsoft.HybridCompute/privateLinkScopes-networkSecurityPerimeterConfigurations.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"resourceType": "privateLinkScopes/networkSecurityPerimeterConfigurations",
3-
"apiVersion": "2024-07-10",
3+
"apiVersion": "2024-07-31-preview",
44
"learnMore": {
55
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
66
},

0 commit comments

Comments
 (0)