-
Notifications
You must be signed in to change notification settings - Fork 31
Azurestack Aks admin commands #109
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 15 commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
03165e6
AKS Admin initial version
cf7dc74
Removing generated files
90fc96f
Merge branch 'dev' into aksadminchanges
bganapa 751b129
Adding AKS admin pester test
9be15c6
Merge branch 'aksadminchanges' of https://github.com/Bhuvaneswari-San…
7001dc5
Merge branch 'dev' into aksadminchanges
Bhuvaneswari-Santharam 26170b1
Pester test changes for aks admin
61868c2
Merge branch 'dev' into aksadminchanges
bganapa fc9e10d
Merge branch 'dev' into aksadminchanges
bganapa c21b443
Merge branch 'dev' into aksadminchanges
bganapa a227fc0
Adding env.json to container service test
31ddaa6
Merge branch 'aksadminchanges' of https://github.com/Bhuvaneswari-San…
ce6b41e
Adding docs and examples for container service
27f2fa4
adding exampls and docs to container service
cffd186
Delete loadEnv.ps1
Bhuvaneswari-Santharam 1d2007a
Adding Example and docs to container service
b3a7f96
Merge branch 'aksadminchanges' of https://github.com/Bhuvaneswari-San…
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
19 changes: 19 additions & 0 deletions
19
src/Azs.ContainerService.Admin/docs/Azs.ContainerService.Admin.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| --- | ||
| Module Name: Azs.ContainerService.Admin | ||
| Module Guid: ceb3fb10-8099-4398-b7a0-1b613eb62bc2 | ||
| Download Help Link: https://docs.microsoft.com/en-us/powershell/module/azs.containerservice.admin | ||
| Help Version: 1.0.0.0 | ||
| Locale: en-US | ||
| --- | ||
|
|
||
| # Azs.ContainerService.Admin Module | ||
| ## Description | ||
| Microsoft AzureStack PowerShell: ContainerService Admin cmdlets | ||
|
|
||
| ## Azs.ContainerService.Admin Cmdlets | ||
| ### [Get-AzsContainerService](Get-AzsContainerService.md) | ||
| Returns a list of managed clusters present in all tenant location. | ||
|
|
||
| ### [Get-AzsContainerServiceQuota](Get-AzsContainerServiceQuota.md) | ||
| Returns a list of container service quotas at the given location. | ||
|
|
100 changes: 100 additions & 0 deletions
100
src/Azs.ContainerService.Admin/docs/Get-AzsContainerService.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,100 @@ | ||
| --- | ||
| external help file: | ||
| Module Name: Azs.ContainerService.Admin | ||
| online version: https://docs.microsoft.com/en-us/powershell/module/azs.containerservice.admin/get-azscontainerservice | ||
| schema: 2.0.0 | ||
| --- | ||
|
|
||
| # Get-AzsContainerService | ||
|
|
||
| ## SYNOPSIS | ||
| Returns a list of managed clusters present in all tenant location. | ||
|
|
||
| ## SYNTAX | ||
|
|
||
| ``` | ||
| Get-AzsContainerService [-Location <String>] [-SubscriptionId <String[]>] [-DefaultProfile <PSObject>] | ||
| [<CommonParameters>] | ||
| ``` | ||
|
|
||
| ## DESCRIPTION | ||
| Returns a list of managed clusters present in all tenant location. | ||
|
|
||
| ## EXAMPLES | ||
|
|
||
| ### -------------------------- EXAMPLE 1 -------------------------- | ||
| ```powershell | ||
| {{ Add code here }} | ||
| ``` | ||
|
|
||
| {{ Add output here }} | ||
|
|
||
| ### -------------------------- EXAMPLE 2 -------------------------- | ||
| ```powershell | ||
| {{ Add code here }} | ||
| ``` | ||
|
|
||
| {{ Add output here }} | ||
|
|
||
| ## PARAMETERS | ||
|
|
||
| ### -DefaultProfile | ||
| The credentials, account, tenant, and subscription used for communication with Azure. | ||
|
|
||
| ```yaml | ||
| Type: System.Management.Automation.PSObject | ||
| Parameter Sets: (All) | ||
| Aliases: AzureRMContext, AzureCredential | ||
|
|
||
| Required: False | ||
| Position: Named | ||
| Default value: None | ||
| Accept pipeline input: False | ||
| Accept wildcard characters: False | ||
| ``` | ||
|
|
||
| ### -Location | ||
| The name of Azure region. | ||
|
|
||
| ```yaml | ||
| Type: System.String | ||
| Parameter Sets: (All) | ||
| Aliases: | ||
|
|
||
| Required: False | ||
| Position: Named | ||
| Default value: (Get-AzLocation)[0].Location | ||
| Accept pipeline input: False | ||
| Accept wildcard characters: False | ||
| ``` | ||
|
|
||
| ### -SubscriptionId | ||
| The ID of the target subscription. | ||
|
|
||
| ```yaml | ||
| Type: System.String[] | ||
| Parameter Sets: (All) | ||
| Aliases: | ||
|
|
||
| Required: False | ||
| Position: Named | ||
| Default value: (Get-AzContext).Subscription.Id | ||
| Accept pipeline input: False | ||
| Accept wildcard characters: False | ||
| ``` | ||
|
|
||
| ### CommonParameters | ||
| This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). | ||
|
|
||
| ## INPUTS | ||
|
|
||
| ## OUTPUTS | ||
|
|
||
| ### Microsoft.Azure.PowerShell.Cmdlets.ContainerServiceAdmin.Models.Api20191101.IContainerServicesListValueItem | ||
|
|
||
| ## NOTES | ||
|
|
||
| ALIASES | ||
|
|
||
| ## RELATED LINKS | ||
|
|
100 changes: 100 additions & 0 deletions
100
src/Azs.ContainerService.Admin/docs/Get-AzsContainerServiceQuota.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,100 @@ | ||
| --- | ||
| external help file: | ||
| Module Name: Azs.ContainerService.Admin | ||
| online version: https://docs.microsoft.com/en-us/powershell/module/azs.containerservice.admin/get-azscontainerservicequota | ||
| schema: 2.0.0 | ||
| --- | ||
|
|
||
| # Get-AzsContainerServiceQuota | ||
|
|
||
| ## SYNOPSIS | ||
| Returns a list of container service quotas at the given location. | ||
|
|
||
| ## SYNTAX | ||
|
|
||
| ``` | ||
| Get-AzsContainerServiceQuota [-Location <String>] [-SubscriptionId <String[]>] [-DefaultProfile <PSObject>] | ||
| [<CommonParameters>] | ||
| ``` | ||
|
|
||
| ## DESCRIPTION | ||
| Returns a list of container service quotas at the given location. | ||
|
|
||
| ## EXAMPLES | ||
|
|
||
| ### -------------------------- EXAMPLE 1 -------------------------- | ||
| ```powershell | ||
| {{ Add code here }} | ||
| ``` | ||
|
|
||
| {{ Add output here }} | ||
|
|
||
| ### -------------------------- EXAMPLE 2 -------------------------- | ||
| ```powershell | ||
| {{ Add code here }} | ||
| ``` | ||
|
|
||
| {{ Add output here }} | ||
|
|
||
| ## PARAMETERS | ||
|
|
||
| ### -DefaultProfile | ||
| The credentials, account, tenant, and subscription used for communication with Azure. | ||
|
|
||
| ```yaml | ||
| Type: System.Management.Automation.PSObject | ||
| Parameter Sets: (All) | ||
| Aliases: AzureRMContext, AzureCredential | ||
|
|
||
| Required: False | ||
| Position: Named | ||
| Default value: None | ||
| Accept pipeline input: False | ||
| Accept wildcard characters: False | ||
| ``` | ||
|
|
||
| ### -Location | ||
| The name of Azure region. | ||
|
|
||
| ```yaml | ||
| Type: System.String | ||
| Parameter Sets: (All) | ||
| Aliases: | ||
|
|
||
| Required: False | ||
| Position: Named | ||
| Default value: (Get-AzLocation)[0].Location | ||
| Accept pipeline input: False | ||
| Accept wildcard characters: False | ||
| ``` | ||
|
|
||
| ### -SubscriptionId | ||
| The ID of the target subscription. | ||
|
|
||
| ```yaml | ||
| Type: System.String[] | ||
| Parameter Sets: (All) | ||
| Aliases: | ||
|
|
||
| Required: False | ||
| Position: Named | ||
| Default value: (Get-AzContext).Subscription.Id | ||
| Accept pipeline input: False | ||
| Accept wildcard characters: False | ||
| ``` | ||
|
|
||
| ### CommonParameters | ||
| This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). | ||
|
|
||
| ## INPUTS | ||
|
|
||
| ## OUTPUTS | ||
|
|
||
| ### Microsoft.Azure.PowerShell.Cmdlets.ContainerServiceAdmin.Models.Api20191101.IContainerServiceQuotaListValueItem | ||
|
|
||
| ## NOTES | ||
|
|
||
| ALIASES | ||
|
|
||
| ## RELATED LINKS | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| # Docs | ||
| This directory contains the documentation of the cmdlets for the `Azs.ContainerService.Admin` module. To run documentation generation, use the `generate-help.ps1` script at the root module folder. Files in this folder will *always be overriden on regeneration*. To update documentation examples, please use the `..\examples` folder. | ||
|
|
||
| ## Info | ||
| - Modifiable: no | ||
| - Generated: all | ||
| - Committed: yes | ||
| - Packaged: yes | ||
|
|
||
| ## Details | ||
| The process of documentation generation loads `Azs.ContainerService.Admin` and analyzes the exported cmdlets from the module. It recognizes the [help comments](https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_comment_based_help) that are generated into the scripts in the `..\exports` folder. Additionally, when writing custom cmdlets in the `..\custom` folder, you can use the help comments syntax, which decorate the exported scripts at build-time. The documentation examples are taken from the `..\examples` folder. |
29 changes: 29 additions & 0 deletions
29
src/Azs.ContainerService.Admin/examples/Get-AzsContainerService.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,29 @@ | ||
| ### Example 1: Get list of managed clusters | ||
| ```powershell | ||
| PS C:\> Get-AzsContainerService -Location "redmond" | ConvertTo-Json | ||
| [ | ||
| { | ||
| "CreationDate": "2021-08-24T21:33:46Z", | ||
| "Id": "/subscriptions/f9712d12-aa4d-4d37-8f46-fabf3c07c836/providers/Microsoft.ContainerService.Admin/locations/redmond/managedclusters/testaksux", | ||
| "Location": "redmond", | ||
| "Name": "redmond/testaksux", | ||
| "OrchestratorVersion": "1.19.11", | ||
| "PropertiesId": "/subscriptions/16661f04-6eca-4ccb-acef-3624fc128005/resourcegroups/testaksuxrg/providers/Microsoft.ContainerService/managedClusters/testaksux", | ||
| "PropertiesName": "testaksux", | ||
| "ProvisioningState": "Succeeded", | ||
| "SubscriptionId": "16661f04-6eca-4ccb-acef-3624fc128005", | ||
| "Type": "Microsoft.ContainerService.Admin/locations/managedclusters" | ||
| }, | ||
| { | ||
| "CreationDate": "2021-08-25T20:02:38Z", | ||
| "Id": "/subscriptions/f9712d12-aa4d-4d37-8f46-fabf3c07c836/providers/Microsoft.ContainerService.Admin/locations/redmond/managedclusters/testaksaddon", | ||
| "Location": "redmond", | ||
| "Name": "redmond/testaksaddon", | ||
| "OrchestratorVersion": "1.19.11", | ||
| "PropertiesId": "/subscriptions/a174daa5-4b9c-4745-8d80-ca8a6c1e2279/resourcegroups/testaksaddonrg/providers/Microsoft.ContainerService/managedClusters/testaksaddon", | ||
| "PropertiesName": "testaksaddon", | ||
| "ProvisioningState": "Succeeded", | ||
| "SubscriptionId": "a174daa5-4b9c-4745-8d80-ca8a6c1e2279", | ||
| "Type": "Microsoft.ContainerService.Admin/locations/managedclusters" | ||
| } | ||
| ] |
9 changes: 9 additions & 0 deletions
9
src/Azs.ContainerService.Admin/examples/Get-AzsContainerServiceQuota.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| ### Example 1: Get Quota for Container Service | ||
| ```powershell | ||
| PS C:\> Get-AzsContainerServiceQuota -Location "redmond" | ConvertTo-Json | ||
| { | ||
| "Id": "/subscriptions/f9712d12-aa4d-4d37-8f46-fabf3c07c836/providers/Microsoft.ContainerService.Admin/locations/redmond/quotas/Unlimited", | ||
| "Name": "redmond/Unlimited", | ||
| "PropertiesName": "Unlimited", | ||
| "Type": "Microsoft.ContainerService.Admin/locations/quotas" | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,92 @@ | ||
| <!-- region Generated --> | ||
| # Azs.ContainerService.Admin | ||
| This directory contains the PowerShell module for the ContainerServiceAdmin service. | ||
|
|
||
| --- | ||
| ## Status | ||
| [](https://www.powershellgallery.com/packages/Azs.ContainerService.Admin/) | ||
|
|
||
| ## Info | ||
| - Modifiable: yes | ||
| - Generated: all | ||
| - Committed: yes | ||
| - Packaged: yes | ||
|
|
||
| --- | ||
| ## Detail | ||
| This module was primarily generated via [AutoRest](https://github.com/Azure/autorest) using the [PowerShell](https://github.com/Azure/autorest.powershell) extension. | ||
|
|
||
| ## Module Requirements | ||
| - [Az.Accounts module](https://www.powershellgallery.com/packages/Az.Accounts/), version 2.2.3 or greater | ||
|
|
||
| ## Authentication | ||
| AutoRest does not generate authentication code for the module. Authentication is handled via Az.Accounts by altering the HTTP payload before it is sent. | ||
|
|
||
| ## Development | ||
| For information on how to develop for `Azs.ContainerService.Admin`, see [how-to.md](how-to.md). | ||
| <!-- endregion --> | ||
|
|
||
| ## Generation Requirements | ||
| Use of the beta version of `autorest.powershell` generator requires the following: | ||
| - [NodeJS LTS](https://nodejs.org) (10.15.x LTS preferred) | ||
| - **Note**: It *will not work* with Node < 10.x. Using 11.x builds may cause issues as they may introduce instability or breaking changes. | ||
| > If you want an easy way to install and update Node, [NVS - Node Version Switcher](../nodejs/installing-via-nvs.md) or [NVM - Node Version Manager](../nodejs/installing-via-nvm.md) is recommended. | ||
| - [AutoRest](https://aka.ms/autorest) v3 beta <br>`npm install -g autorest@beta`<br> | ||
| - PowerShell 6.0 or greater | ||
| - If you don't have it installed, you can use the cross-platform npm package <br>`npm install -g pwsh`<br> | ||
| - .NET Core SDK 2.0 or greater | ||
| - If you don't have it installed, you can use the cross-platform npm package <br>`npm install -g dotnet-sdk-2.2`<br> | ||
|
|
||
| ## Run Generation | ||
| In this directory, run AutoRest: | ||
| > `autorest` | ||
|
|
||
| --- | ||
| ### AutoRest Configuration | ||
| > see https://aka.ms/autorest | ||
|
|
||
| ``` yaml | ||
| require: | ||
| - $(this-folder)/../readme.azurestack.md | ||
| - $(repo)/specification/azsadmin/resource-manager/containerservice/readme.azsautogen.md | ||
|
|
||
| metadata: | ||
| description: 'Microsoft AzureStack PowerShell: ContainerService Admin cmdlets' | ||
|
|
||
| ### PSD1 metadata changes | ||
| subject-prefix: '' | ||
| module-version: 0.1.0 | ||
| service-name: ContainerServiceAdmin | ||
|
|
||
| ### File Renames | ||
| ### IMPORTANT - Note that the following settings are case sensitive ### | ||
| module-name: Azs.ContainerService.Admin | ||
| csproj: Azs.ContainerService.Admin.csproj | ||
| psd1: Azs.ContainerService.Admin.psd1 | ||
| psm1: Azs.ContainerService.Admin.psm1 | ||
| ``` | ||
|
|
||
| ### Parameter default values | ||
| ``` yaml | ||
| directive: | ||
|
|
||
| # Add release notes | ||
| - from: Azs.ContainerService.Admin.nuspec | ||
| where: $ | ||
| transform: $ = $.replace('<releaseNotes></releaseNotes>', '<releaseNotes>AzureStack Hub Admin module generated with https://github.com/Azure/autorest.powershell.</releaseNotes>'); | ||
|
|
||
| # Add Az.Accounts/Az.Resources as dependencies | ||
| - from: Azs.ContainerService.Admin.nuspec | ||
| where: $ | ||
| transform: $ = $.replace('<dependency id=\"Az.Accounts\" version=\"1.6.0\" />', '<dependency id="Az.Accounts" version="2.2.8" />\n <dependency id="Az.Resources" version="[0.11.0]" />'); | ||
|
|
||
| # PSD1 changes for RequiredModules | ||
| - from: source-file-csharp | ||
| where: $ | ||
| transform: $ = $.replace('sb.AppendLine\(\$@\"\{Indent\}RequiredAssemblies = \'\{\"./bin/Azs.ContainerService.Admin.private.dll\"\}\'\"\);', 'sb.AppendLine\(\$@\"\{Indent\}RequiredAssemblies = \'\{\"./bin/Azs.ContainerService.Admin.private.dll\"\}\'\"\);\n sb.AppendLine\(\$@\"\{Indent\}RequiredModules = @\(@\{\{ModuleName = \'Az.Accounts\'; ModuleVersion = \'2.2.8\'; \}\}, @\{\{ModuleName = \'Az.Resources\'; RequiredVersion = \'0.11.0\'; \}\}\)\"\);'); | ||
|
|
||
| # PSD1 changes for ReleaseNotes | ||
| - from: source-file-csharp | ||
| where: $ | ||
| transform: $ = $.replace('sb.AppendLine\(\$@\"\{Indent\}\{Indent\}\{Indent\}ReleaseNotes = \'\'\"\);', 'sb.AppendLine\(\$@\"\{Indent\}\{Indent\}\{Indent\}ReleaseNotes = \'AzureStack Hub Admin module generated with https://github.com/Azure/autorest.powershell\'\"\);' ); | ||
| ``` |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.