Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Next Next commit
Move ConnectedMachine to main
  • Loading branch information
azure-powershell-bot committed Nov 12, 2024
commit cb02f3230b60163c429da4bc0ec6e58b9775c5c5
1,206 changes: 1,158 additions & 48 deletions src/ConnectedMachine/ConnectedMachine.Autorest/Az.ConnectedMachine.format.ps1xml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
DotNetFrameworkVersion = '4.7.2'
RequiredAssemblies = './bin/Az.ConnectedMachine.private.dll'
FormatsToProcess = './Az.ConnectedMachine.format.ps1xml'
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'
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'
PrivateData = @{
PSData = @{
Tags = 'Azure', 'ResourceManager', 'ARM', 'PSModule', 'ConnectedMachine'
Expand Down
115 changes: 65 additions & 50 deletions src/ConnectedMachine/ConnectedMachine.Autorest/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,12 @@ In this directory, run AutoRest:
> see https://aka.ms/autorest

``` yaml
commit: f41d0c9332078cb2ef07b749081d94915255ada5
commit: a9980ec5181a161dd26c5277f7651722b60503ea
require:
- $(this-folder)/../../readme.azure.noprofile.md
input-file:
- $(repo)/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/HybridCompute.json
- $(repo)/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/privateLinkScopes.json
- $(repo)/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/preview/2024-07-31-preview/HybridCompute.json
- $(repo)/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/preview/2024-07-31-preview/privateLinkScopes.json

module-version: 0.1.0
title: ConnectedMachine
Expand Down Expand Up @@ -176,41 +176,41 @@ directive:
}

# add 200 response to run-command delete - comment out for stable release
# - from: swagger-document
# where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/runCommands/{runCommandName}"].delete.responses
# transform: >-
# return {
# "200": {
# "description": "OK"
# },
# "202": {
# "description": "Accepted",
# "headers": {
# "Location": {
# "description": "The URL of the resource used to check the status of the asynchronous operation.",
# "type": "string"
# },
# "Retry-After": {
# "description": "The recommended number of seconds to wait before calling the URI specified in Azure-AsyncOperation.",
# "type": "integer",
# "format": "int32"
# },
# "Azure-AsyncOperation": {
# "description": "The URI to poll for completion status.",
# "type": "string"
# }
# }
# },
# "204": {
# "description": "No Content"
# },
# "default": {
# "description": "Error response describing why the operation failed.",
# "schema": {
# "$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ErrorResponse"
# }
# }
# }
- from: swagger-document
where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/runCommands/{runCommandName}"].delete.responses
transform: >-
return {
"200": {
"description": "OK"
},
"202": {
"description": "Accepted",
"headers": {
"Location": {
"description": "The URL of the resource used to check the status of the asynchronous operation.",
"type": "string"
},
"Retry-After": {
"description": "The recommended number of seconds to wait before calling the URI specified in Azure-AsyncOperation.",
"type": "integer",
"format": "int32"
},
"Azure-AsyncOperation": {
"description": "The URI to poll for completion status.",
"type": "string"
}
}
},
"204": {
"description": "No Content"
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ErrorResponse"
}
}
}

# GetViaIdentity isn't useful until Azure PowerShell supports piping of different subjects
- where:
Expand Down Expand Up @@ -259,6 +259,11 @@ directive:
parameter-name: AgentUpgradeEnableAutomaticUpgrade
set:
parameter-name: AgentUpgradeEnableAutomatic
- where:
subject: MachineRunCommand
parameter-name: SubscriptionId
set:
alias: Subscription

# Rename Tag to Tags
- where:
Expand Down Expand Up @@ -324,23 +329,18 @@ directive:
subject: MachineRunCommand
verb: Set
remove: true
# internal API
- where:
subject: LicenseProfile
remove: true
- where:
subject: Extension
variant: Upgrade
remove: true

# we will release gateway and setting commands in a seperate module - comment out for stable release
# - where:
# subject: Gateway
# remove: true
# Remove when this API version is added - comment out for stable release
# - where:
# subject: Setting
# remove: true
# we will release gateway and setting commands in a seperate module
- where:
subject: Gateway
remove: true
- where:
subject: Setting
remove: true

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

# hide Set-AzConnectedLicenseProfile (PUT) from user and keep Update-AzConnectedLicenseProfile (PATCH)
- where:
subject: LicenseProfile
verb: Set
remove: true

# We don't want user to talk directly to the network configuration API
- where:
subject: NetworkConfiguration
Expand Down Expand Up @@ -392,5 +398,14 @@ directive:
- model-cmdlet:
- model-name: LicenseDetails
cmdlet-name: New-AzConnectedLicenseDetail

# Generate complex object for Update-AzConnectedLicenseProfile
- model-cmdlet:
- model-name: ProductFeatureUpdate
cmdlet-name: Update-AzConnectedLicenseProfileFeature
# Generate complex object for New-AzConnectedLicenseProfile, change prefix to New- will cause CI styling issue
- model-cmdlet:
- model-name: ProductFeature
cmdlet-name: New-AzConnectedLicenseProfileFeature

```
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"resourceType": "licenses",
"apiVersion": "2024-07-10",
"apiVersion": "2024-07-31-preview",
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"resourceType": "locations/publishers/extensionTypes/versions",
"apiVersion": "2024-07-10",
"apiVersion": "2024-07-31-preview",
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"resourceType": "machines/extensions",
"apiVersion": "2024-07-10",
"apiVersion": "2024-07-31-preview",
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
},
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
{
"resourceType": "machines/licenseProfiles",
"apiVersion": "2024-07-31-preview",
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
},
"commands": [
{
"name": "Get-AzConnectedLicenseProfile",
"description": "Retrieves information about the view of a license profile.",
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/licenseProfiles/{licenseProfileName}",
"help": {
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine/get-azconnectedlicenseprofile"
},
"parameterSets": [
{
"parameters": [
"-MachineName <String>",
"-ResourceGroupName <String>",
"[-SubscriptionId <String[]>]"
]
}
]
},
"examples": [
{
"description": "Retrieves information about the view of a license profile.",
"parameters": [
{
"name": "-MachineName",
"value": "[Path.machineName]"
},
{
"name": "-ResourceGroupName",
"value": "[Path.resourceGroupName]"
},
{
"name": "-SubscriptionId",
"value": "[Path.subscriptionId]"
}
]
}
]
},
{
"name": "Remove-AzConnectedLicenseProfile",
"description": "The operation to delete a license profile.",
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/licenseProfiles/{licenseProfileName}",
"help": {
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine/remove-azconnectedlicenseprofile"
},
"parameterSets": [
{
"parameters": [
"-MachineName <String>",
"-ResourceGroupName <String>",
"[-SubscriptionId <String>]"
]
}
]
},
"examples": [
{
"description": "The operation to delete a license profile.",
"parameters": [
{
"name": "-MachineName",
"value": "[Path.machineName]"
},
{
"name": "-ResourceGroupName",
"value": "[Path.resourceGroupName]"
},
{
"name": "-SubscriptionId",
"value": "[Path.subscriptionId]"
}
]
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
{
"resourceType": "machines/runCommands",
"apiVersion": "2024-07-31-preview",
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
},
"commands": [
{
"name": "Get-AzConnectedMachineRunCommand",
"description": "The operation to get a run command.",
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/runCommands/{runCommandName}",
"help": {
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine/get-azconnectedmachineruncommand"
},
"parameterSets": [
{
"parameters": [
"-MachineName <String>",
"-ResourceGroupName <String>",
"-RunCommandName <String>",
"[-SubscriptionId <String[]>]"
]
}
]
},
"examples": [
{
"description": "The operation to get a run command.",
"parameters": [
{
"name": "-MachineName",
"value": "[Path.machineName]"
},
{
"name": "-ResourceGroupName",
"value": "[Path.resourceGroupName]"
},
{
"name": "-RunCommandName",
"value": "[Path.runCommandName]"
},
{
"name": "-SubscriptionId",
"value": "[Path.subscriptionId]"
}
]
}
]
},
{
"name": "Remove-AzConnectedMachineRunCommand",
"description": "The operation to delete a run command.",
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCompute/machines/{machineName}/runCommands/{runCommandName}",
"help": {
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine/remove-azconnectedmachineruncommand"
},
"parameterSets": [
{
"parameters": [
"-MachineName <String>",
"-ResourceGroupName <String>",
"-RunCommandName <String>",
"[-SubscriptionId <String>]"
]
}
]
},
"examples": [
{
"description": "The operation to delete a run command.",
"parameters": [
{
"name": "-MachineName",
"value": "[Path.machineName]"
},
{
"name": "-ResourceGroupName",
"value": "[Path.resourceGroupName]"
},
{
"name": "-RunCommandName",
"value": "[Path.runCommandName]"
},
{
"name": "-SubscriptionId",
"value": "[Path.subscriptionId]"
}
]
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"resourceType": "machines",
"apiVersion": "2024-07-10",
"apiVersion": "2024-07-31-preview",
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"resourceType": "privateLinkScopes/networkSecurityPerimeterConfigurations",
"apiVersion": "2024-07-10",
"apiVersion": "2024-07-31-preview",
"learnMore": {
"url": "https://learn.microsoft.com/powershell/module/az.connectedmachine"
},
Expand Down
Loading
Loading