Skip to content

Commit

Permalink
fix(azure): ensure correct properties are used when adjusting SKU and…
Browse files Browse the repository at this point in the history
… storage for postgres (#1514)

<!--- Provide a general summary of your changes in the Title above -->

## Description

<!--- Describe your changes in detail -->

By setting 256gb as storage size, the IOPS will be p15

## Related Issue(s)

- #{issue number}

## Verification

- [ ] **Your** code builds clean without any errors or warnings
- [ ] Manual testing done (required)
- [ ] Relevant automated test added (if you find this hard, leave it and
we'll help out)

## Documentation

- [ ] Documentation is updated (either in `docs`-directory, Altinnpedia
or a separate linked PR in
[altinn-studio-docs.](https://github.com/Altinn/altinn-studio-docs), if
applicable)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Simplified PostgreSQL storage configuration by removing the `tier`
specification, streamlining the setup process.
  
- **Bug Fixes**
- Addressed inconsistencies in the PostgreSQL resource definitions
related to storage tier configurations.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
  • Loading branch information
arealmaas authored Nov 22, 2024
1 parent a87b3e1 commit c51d2f5
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 5 deletions.
1 change: 0 additions & 1 deletion .azure/infrastructure/prod.bicepparam
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ param postgresConfiguration = {
storage: {
storageSizeGB: 256
autoGrow: 'Enabled'
tier: 'P15'
type: 'Premium_LRS'
}
enableIndexTuning: false
Expand Down
1 change: 0 additions & 1 deletion .azure/infrastructure/yt01.bicepparam
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ param postgresConfiguration = {
storage: {
storageSizeGB: 256
autoGrow: 'Enabled'
tier: 'P15'
type: 'Premium_LRS'
}
enableIndexTuning: true
Expand Down
3 changes: 0 additions & 3 deletions .azure/modules/postgreSql/create.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@ type StorageConfiguration = {
autoGrow: 'Enabled' | 'Disabled'
@description('The type of storage account to use. Default is Premium_LRS.')
type: 'Premium_LRS' | 'PremiumV2_LRS'
@description('Required when type is Premium_LRS or PremiumV2_LRS')
tier: 'P1' | 'P2' | 'P3' | 'P4' | 'P6' | 'P10' | 'P15' | 'P20' | 'P30' | 'P40' | 'P50' | 'P60' | 'P70' | 'P80' | null
}

@description('The storage configuration for the PostgreSQL server')
Expand Down Expand Up @@ -112,7 +110,6 @@ resource postgres 'Microsoft.DBforPostgreSQL/flexibleServers@2024-08-01' = {
storageSizeGB: storage.storageSizeGB
autoGrow: storage.autoGrow
type: storage.type
tier: storage.tier
}
dataEncryption: {
type: 'SystemManaged'
Expand Down

0 comments on commit c51d2f5

Please sign in to comment.