Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
e71e750
Initial code changes
rjaini Apr 13, 2021
e953c3d
ACR auto-generating cmdlets.
larisaborodina Jun 8, 2021
d40995a
Merge pull request #1 from larisaborodina/release/acrchanges
rjaini Jun 9, 2021
8bc4b41
ACR auto-generating cmdlets. - #2
larisaborodina Jun 14, 2021
579d76f
Merge pull request #2 from larisaborodina/release/acrchanges
rjaini Jun 14, 2021
d16c156
Add pester tests for all the cmdlets.
larisaborodina Aug 5, 2021
d62418c
Merge branch 'release/acrchanges' of https://github.com/larisaborodin…
larisaborodina Aug 5, 2021
f4aaa5e
Merge pull request #3 from larisaborodina/release/acrchanges
rjaini Aug 5, 2021
ada05b3
Merge branch 'dev' into release/acrchanges
larisaborodina Aug 10, 2021
5f81725
Add examples for all the cmdlets.
larisaborodina Aug 17, 2021
31a2056
Merge pull request #4 from larisaborodina/release/acrchanges
larisaborodina Aug 17, 2021
55ea749
Increase vertion to 0.2.0 to avoid clashing with manually released 0.…
larisaborodina Aug 17, 2021
5c1e28b
Merge pull request #5 from larisaborodina/release/acrchanges
larisaborodina Aug 17, 2021
dba2afd
Merge branch 'Azure:dev' into release/acrchanges
larisaborodina Aug 19, 2021
be23ddd
Merge branch 'Azure:dev' into release/acrchanges
larisaborodina Aug 19, 2021
10211aa
Replace Read-AzsContainerRegistry to Get-AzsContainerRegistry.
larisaborodina Aug 19, 2021
e983df3
Merge pull request #6 from larisaborodina/release/acrchanges
larisaborodina Aug 19, 2021
b97a244
Add missed Get-AzsContainerRegistry.Recording.json
larisaborodina Aug 19, 2021
d3ffb18
Merge pull request #7 from larisaborodina/release/acrchanges
larisaborodina Aug 19, 2021
ec31d3b
Add docs for all cmdlets
larisaborodina Aug 20, 2021
53a98cf
Merge branch 'release/acrchanges' of https://github.com/larisaborodin…
larisaborodina Aug 20, 2021
4a22f44
Merge pull request #8 from larisaborodina/release/acrchanges
larisaborodina Aug 20, 2021
26b3572
Initial code changes
rjaini Apr 13, 2021
ea79435
ACR auto-generating cmdlets.
larisaborodina Jun 8, 2021
4181db5
ACR auto-generating cmdlets. - #2
larisaborodina Jun 14, 2021
0e02a3f
Add pester tests for all the cmdlets.
larisaborodina Aug 5, 2021
fe2ac98
Add examples for all the cmdlets.
larisaborodina Aug 17, 2021
5f361ca
Increase vertion to 0.2.0 to avoid clashing with manually released 0.…
larisaborodina Aug 17, 2021
617f1f0
Replace Read-AzsContainerRegistry to Get-AzsContainerRegistry.
larisaborodina Aug 19, 2021
34bf575
Add missed Get-AzsContainerRegistry.Recording.json
larisaborodina Aug 19, 2021
b78246c
Add docs for all cmdlets
larisaborodina Aug 20, 2021
7b24676
Merge branch 'release/acrchanges' of https://github.com/larisaborodin…
larisaborodina Aug 23, 2021
7a689a8
Merge pull request #9 from larisaborodina/release/acrchanges
larisaborodina Aug 23, 2021
c641788
Merge branch 'Azure:dev' into release/acrchanges
larisaborodina Aug 27, 2021
f81437a
Fixed tests running locally, updated docs.
larisaborodina Aug 30, 2021
36f9520
Merge pull request #10 from larisaborodina/release/acrchanges
larisaborodina Aug 30, 2021
cfa1ba7
adding loadEnvJson file for tests
bganapa Aug 31, 2021
c30c4d8
Pester Test fixes.
larisaborodina Aug 31, 2021
810898c
Merge pull request #11 from larisaborodina/release/acrchanges
larisaborodina Aug 31, 2021
28ef012
Merge branch 'Azure:dev' into release/acrchanges
larisaborodina Sep 1, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
Module Name: Azs.ContainerRegistry.Admin
Module Guid: 27950488-3e83-458b-8797-6db82864cf62
Module Guid: 900db1dd-8338-4e8f-a01c-81ab98484955
Download Help Link: https://docs.microsoft.com/en-us/powershell/module/azs.containerregistry.admin
Help Version: 1.0.0.0
Locale: en-US
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,9 @@ Returns a list of container registries present in all tenant location.

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Get List Azs Container Registries
```powershell
Get-AzsContainerRegistry
```
PS C:\> Get-AzsContainerRegistry

{
"CreationDate": "\/Date(1629160842681)\/",
Expand All @@ -39,6 +38,9 @@ Get-AzsContainerRegistry
"SubscriptionId": "72b77b1b-3e43-4d00-8b5b-be6beceb7f3a",
"Type": "Microsoft.ContainerRegistry.Admin/locations/registries"
}
```

Returns a list of container registries present in all tenant location.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,9 @@ Returns container registry capacity property.

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Get Azs ContainerRegistry Capacity
```powershell
Get-AzsContainerRegistryCapacity
```
PS C:\> Get-AzsContainerRegistryCapacity

{
"AllowPush": true,
Expand All @@ -48,6 +47,9 @@ Get-AzsContainerRegistryCapacity
"RegistriesConsumptionInGiB": 0,
"Type": "Microsoft.ContainerRegistry.Admin/locations/capacities"
}
```

Returns container registry capacity property.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,17 +35,19 @@ Returns the specified configuration details.

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Get AzsContainerRegistry Configuration
```powershell
Get-AzsContainerRegistryConfiguration
```
PS C:\> Get-AzsContainerRegistryConfiguration

{{
"Id": "/subscriptions/7e41090c-4aa7-40bc-856a-a993f8fbd215/providers/Microsoft.ContainerRegistry.Admin/locations/redmond/configurations/Default",
"MaximumCapacityInGiB": 2000,
"Name": "redmond/Default",
"Type": "Microsoft.ContainerRegistry.Admin/locations/configurations"
}
```

Returns the specified configuration details.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,9 @@ Returns the specified container registry quota.

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Get List Azs ContainerRegistry Quotas
```powershell
Get-AzsContainerRegistryQuota
```
PS C:\> Get-AzsContainerRegistryQuota

[
{
Expand All @@ -56,11 +55,13 @@ Get-AzsContainerRegistryQuota
"Type": "Microsoft.ContainerRegistry.Admin/locations/quotas"
}
]
```

### -------------------------- EXAMPLE 2 --------------------------
Returns a list of container registry quotas at the given location.

### Example 2: Get Azs ContainerRegistry Quota by Name
```powershell
Get-AzsContainerRegistryQuota -Name "Default quota"
```
PS C:\> Get-AzsContainerRegistryQuota -Name "Default quota"

{
"CapacityPerRegistryInGiB": 20,
Expand All @@ -69,6 +70,9 @@ Get-AzsContainerRegistryQuota -Name "Default quota"
"NumberOfRegistry": 20,
"Type": "Microsoft.ContainerRegistry.Admin/locations/quotas"
}
```

Returns the specified container registry quota.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,9 @@ Returns the status of the container registry setup.

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Get Azs ContainerRegistry Setup Status
```powershell
Get-AzsContainerRegistrySetupStatus
```
PS C:\> Get-AzsContainerRegistrySetupStatus

{
"id": "/subscriptions/7e41090c-4aa7-40bc-856a-a993f8fbd215/providers/Microsoft.ContainerRegistry.Setup/locations/redmond/setup/value",
Expand All @@ -42,6 +41,9 @@ Get-AzsContainerRegistrySetupStatus
"status": "Completed"
}
}
```

Returns the status of the container registry setup.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,9 @@ Create or update an existing container registry quota.

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: New Azs ContainerRegistry Quota
```powershell
New-AzsContainerRegistryQuota -QuotaName testquota -CapacityPerRegistryInGib 20 -NumberOfRegistry 20
```
PS C:\> New-AzsContainerRegistryQuota -QuotaName testquota -CapacityPerRegistryInGib 20 -NumberOfRegistry 20

{
"CapacityPerRegistryInGiB": 20,
Expand All @@ -42,6 +41,9 @@ New-AzsContainerRegistryQuota -QuotaName testquota -CapacityPerRegistryInGib 20
"NumberOfRegistry": 20,
"Type": "Microsoft.ContainerRegistry.Admin/locations/quotas"
}
```

Create or update an existing container registry quota.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,13 @@ Delete an existing container registry configuration

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Remove Azs ContainerRegistry Configuration
```powershell
Remove-AzsContainerRegistryConfiguration -ConfigurationName default
```
PS C:\> Remove-AzsContainerRegistryConfiguration -ConfigurationName default

```

Delete an existing container registry configuration.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,13 @@ Delete an existing container registry quota

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Remove Azs ContainerRegistry Configuration
```powershell
Remove-AzsContainerRegistryConfiguration -ConfigurationName default
```
PS C:\> Remove-AzsContainerRegistryConfiguration -ConfigurationName default

```

Delete an existing container registry configuration.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,19 @@ Configure container registry overall configuration properties.

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Set Azs ContainerRegistry Configuration
```powershell
Set-AzsContainerRegistryConfiguration -MaximumCapacityInGib 30 -ConfigurationName default
```
PS C:\> Set-AzsContainerRegistryConfiguration -MaximumCapacityInGib 30 -ConfigurationName default

{
"Id": "/subscriptions/7e41090c-4aa7-40bc-856a-a993f8fbd215/providers/Microsoft.ContainerRegistry.Admin/locations/redmond/configurations/Default",
"MaximumCapacityInGiB": 30,
"Name": "redmond/Default",
"Type": "Microsoft.ContainerRegistry.Admin/locations/configurations"
}
```

Configure container registry overall configuration properties.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,9 @@ Create or update an existing container registry quota.

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Set Azs ContainerRegistry Quota
```powershell
Set-AzsContainerRegistryQuota -QuotaName testquota -CapacityPerRegistryInGib 30 -NumberOfRegistry 30
```
PS C:\> Set-AzsContainerRegistryQuota -QuotaName testquota -CapacityPerRegistryInGib 30 -NumberOfRegistry 30

{
"CapacityPerRegistryInGiB": 30,
Expand All @@ -42,6 +41,9 @@ Set-AzsContainerRegistryQuota -QuotaName testquota -CapacityPerRegistryInGib 30
"NumberOfRegistry": 30,
"Type": "Microsoft.ContainerRegistry.Admin/locations/quotas"
}
```

Update an existing container registry quota.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,13 @@ Invokes container registry certificate uploading and service deployment.

## EXAMPLES

### -------------------------- EXAMPLE 1 --------------------------
### Example 1: Start Azs ContainerRegistry Setup
```powershell
Start-AzsContainerRegistrySetup -Password $password -SslCertInputFile $pfx_cert_path
```
PS C:\> Start-AzsContainerRegistrySetup -Password $password -SslCertInputFile $pfx_cert_path

```

Invokes container registry certificate uploading and service deployment.

## PARAMETERS

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Get-AzsContainerRegistry.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Get-AzsContainerRegistryCapacity.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Get-AzsContainerRegistryConfiguration.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Get-AzsContainerRegistryQuota.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Get-AzsContainerRegistrySetupStatus.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'New-AzsContainerRegistryQuota.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Remove-AzsContainerRegistryConfiguration.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Remove-AzsContainerRegistryQuota.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Set-AzsContainerRegistryConfiguration.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Set-AzsContainerRegistryQuota.Recording.json'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
}
},
"Response": {
"StatusCode": 409,
"StatusCode": 201,
"Headers": {
"Cache-Control": [ "no-cache" ],
"Pragma": [ "no-cache" ],
Expand All @@ -31,7 +31,7 @@
"Content-Type": [ "application/json; charset=utf-8" ],
"Expires": [ "-1" ]
},
"Content": "{\"error\":{\"code\":\"AcrAlreadyDeployed\",\"message\":\"Container registry deployment has already been successfully completed. It is not allowed to repeat deployment\"}}",
"Content": "{\"id\":\"/subscriptions/7e41090c-4aa7-40bc-856a-a993f8fbd215/providers/Microsoft.ContainerRegistry.Setup/locations/redmond/setup/value\",\"name\":\"redmond/value\",\"type\":\"Microsoft.ContainerRegistry.Setup/locations/setup\",\"properties\":{\"statusUri\":\"https://adminmanagement.redmond.ext-v.masd.stbtest.microsoft.com/subscriptions/731e84f5-d31e-4c6a-aa1d-546d6bfb2789/providers/Microsoft.ContainerRegistry.Setup/locations/local/setup?api-version=2019-11-01-preview\"}}",
"isContentBase64": false
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot 'loadEnvJson.ps1'
if (-Not (Test-Path -Path $loadEnvPath)) {
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnv.ps1'
$loadEnvPath = Join-Path $PSScriptRoot '..\loadEnvJson.ps1'
}
. ($loadEnvPath)
$TestRecordingFile = Join-Path $PSScriptRoot 'Start-AzsContainerRegistrySetup.Recording.json'
Expand All @@ -13,7 +13,7 @@ while(-not $mockingPath) {

Describe 'Start-AzsContainerRegistrySetup' {
$password = ConvertTo-SecureString "password" -AsPlainText -Force
$pfx_cert_path = "C:\CloudDeployment\Setup\Certificates\ADFS\Container Registry\SSL.pfx"
$pfx_cert_path = Join-Path $PSScriptRoot 'SSL.pem'

{ Start-AzsContainerRegistrySetup -Password $password -SslCertInputFile $pfx_cert_path } | Should Not Throw
}
7 changes: 7 additions & 0 deletions src/Azs.ContainerRegistry.Admin/test/env.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"SubscriptionId": "7e41090c-4aa7-40bc-856a-a993f8fbd215",
"Tenant": "91d73aac-4fb0-4ff2-a437-9d18d1658671",
"ResourceGroup": "testrg",
"Location": "redmond",
"TenantSubscriptionId": "95990F40-5F11-490D-B323-9317191D347A"
}
Loading