Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Users/alsehr/881 rsv fix #885

Merged
merged 2 commits into from
Jan 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
Expand Up @@ -25,7 +25,7 @@ var builtInRoleNames = {
'Virtual Machine Contributor': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '9980e02c-c2be-4d73-94e8-173b1dc7cf3c')
}

resource rsv 'Microsoft.RecoveryServices/vaults@2021-08-01' existing = {
resource rsv 'Microsoft.RecoveryServices/vaults@2021-12-01' existing = {
name: last(split(resourceId, '/'))
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,11 @@ module pid_cuaId './.bicep/nested_cuaId.bicep' = if (!empty(cuaId)) {
params: {}
}

resource rsv 'Microsoft.RecoveryServices/vaults@2021-08-01' existing = {
resource rsv 'Microsoft.RecoveryServices/vaults@2021-12-01' existing = {
name: recoveryVaultName
}

resource backupConfig 'Microsoft.RecoveryServices/vaults/backupconfig@2021-08-01' = {
resource backupConfig 'Microsoft.RecoveryServices/vaults/backupconfig@2021-10-01' = {
name: name
parent: rsv
properties: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This module deploys recovery services vault backup config.

| Resource Type | API Version |
| :-- | :-- |
| `Microsoft.RecoveryServices/vaults/backupconfig` | 2021-08-01 |
| `Microsoft.RecoveryServices/vaults/backupconfig` | 2021-10-01 |

## Parameters

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ module pid_cuaId './.bicep/nested_cuaId.bicep' = if (!empty(cuaId)) {
params: {}
}

resource rsv 'Microsoft.RecoveryServices/vaults@2021-08-01' existing = {
resource rsv 'Microsoft.RecoveryServices/vaults@2021-12-01' existing = {
name: recoveryVaultName
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ module pid_cuaId './.bicep/nested_cuaId.bicep' = if (!empty(cuaId)) {
params: {}
}

resource rsv 'Microsoft.RecoveryServices/vaults@2021-08-01' existing = {
resource rsv 'Microsoft.RecoveryServices/vaults@2021-12-01' existing = {
name: recoveryVaultName
}

Expand Down
4 changes: 2 additions & 2 deletions arm/Microsoft.RecoveryServices/vaults/deploy.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -130,11 +130,11 @@ module pid_cuaId '.bicep/nested_cuaId.bicep' = if (!empty(cuaId)) {
params: {}
}

resource rsv 'Microsoft.RecoveryServices/vaults@2021-08-01' = {
resource rsv 'Microsoft.RecoveryServices/vaults@2021-12-01' = {
name: name
location: location
tags: tags
identity: identity
identity: any(identity)
sku: {
name: 'RS0'
tier: 'Standard'
Expand Down
2 changes: 1 addition & 1 deletion arm/Microsoft.RecoveryServices/vaults/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ This module deploys a recovery service vault.
| `Microsoft.Authorization/locks` | 2016-09-01 |
| `Microsoft.Authorization/roleAssignments` | 2020-04-01-preview |
| `Microsoft.Insights/diagnosticSettings` | 2021-05-01-preview |
| `Microsoft.RecoveryServices/vaults` | 2021-08-01 |
| `Microsoft.RecoveryServices/vaults` | 2021-12-01 |
| `Microsoft.RecoveryServices/vaults/backupconfig` | 2021-08-01 |
| `Microsoft.RecoveryServices/vaults/backupFabrics/protectionContainers` | 2021-08-01 |
| `Microsoft.RecoveryServices/vaults/backupPolicies` | 2021-08-01 |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ function Invoke-ResourceRemoval {
$null = Remove-AzResource -ResourceId $resourceId -Force -ErrorAction 'Stop'
break
}
'Microsoft.RecoveryServices/vaults/backupstorageconfig' {
# Not a 'resource' that can be removed, but represents settings on the RSV. The config is deleted with the RSV
break
}
'Microsoft.RecoveryServices/vaults' {
# Pre-Removal
# -----------
Expand Down