terraform-provider-azurerm
terraform-provider-azurerm copied to clipboard
Updated API version of `container_group` from `2021-03-01` to `2021-10-01`
This PR updates API, used by container_group
from 2021-03-01
to 2021-10-01
.
API changes: https://docs.microsoft.com/en-us/azure/templates/microsoft.containerinstance/change-log/containergroups#2021-10-01
Included changes:
- Removed
network_profile_id
(deprecated since2021-07-01
). - Added
image_registry_credentials.user_assigned_identity_id
(added in2021-07-01
). - Added
subnets
(added in2021-07-01
). - Added
zones
(added in2021-09-01
). - Added
dns_name_label_reuse_policy
(added in2021-10-01
).
Notes:
- As with #17416, I had to set
username
andpassword
toOptional: true
as there are multipleimage_registry_credentials
and it requires eitherusername
ofuser_assigned_identity_id
, and currently we cannot useExactlyOneOf
orAtLeastOneOf
in a loop context with multiple elements.
Fixes #17371.
Tests:
TF_ACC=1 go test -v -timeout 300000s -run ^TestAccContainerGroup_ github.com/hashicorp/terraform-provider-azurerm/internal/services/containers/
...
=== CONT TestAccContainerGroup_SystemAssignedIdentity
=== CONT TestAccContainerGroup_gitRepoVolume
=== CONT TestAccContainerGroup_imageRegistryCredentials
=== CONT TestAccContainerGroup_linuxBasicTagsUpdate
--- PASS: TestAccContainerGroup_imageRegistryCredentials (192.04s)
=== CONT TestAccContainerGroup_withPrivateEmpty
--- PASS: TestAccContainerGroup_SystemAssignedIdentity (194.49s)
=== CONT TestAccContainerGroup_windowsComplete
--- PASS: TestAccContainerGroup_gitRepoVolume (208.86s)
=== CONT TestAccContainerGroup_windowsBasic
--- PASS: TestAccContainerGroup_linuxBasicTagsUpdate (233.73s)
=== CONT TestAccContainerGroup_SystemAssignedIdentityVirtualNetwork
--- PASS: TestAccContainerGroup_withPrivateEmpty (146.22s)
=== CONT TestAccContainerGroup_virtualNetworkParallel
--- PASS: TestAccContainerGroup_SystemAssignedIdentityVirtualNetwork (247.13s)
=== CONT TestAccContainerGroup_virtualNetwork
--- PASS: TestAccContainerGroup_virtualNetworkParallel (252.23s)
=== CONT TestAccContainerGroup_linuxComplete
--- PASS: TestAccContainerGroup_windowsBasic (462.40s)
=== CONT TestAccContainerGroup_exposedPort
--- PASS: TestAccContainerGroup_virtualNetwork (310.90s)
=== CONT TestAccContainerGroup_exposedPortUpdate
--- PASS: TestAccContainerGroup_exposedPort (146.25s)
=== CONT TestAccContainerGroup_linuxBasicUpdate
--- PASS: TestAccContainerGroup_exposedPortUpdate (212.74s)
=== CONT TestAccContainerGroup_requiresImport
--- PASS: TestAccContainerGroup_linuxBasicUpdate (203.53s)
=== CONT TestAccContainerGroup_SystemAssignedIdentityWithZones
--- PASS: TestAccContainerGroup_windowsComplete (910.18s)
=== CONT TestAccContainerGroup_multipleAssignedIdentities
--- PASS: TestAccContainerGroup_requiresImport (140.12s)
=== CONT TestAccContainerGroup_UserAssignedIdentityWithVirtualNetwork
--- PASS: TestAccContainerGroup_SystemAssignedIdentityWithZones (129.69s)
=== CONT TestAccContainerGroup_UserAssignedIdentity
--- PASS: TestAccContainerGroup_multipleAssignedIdentities (160.36s)
=== CONT TestAccContainerGroup_logTypeUnset
--- PASS: TestAccContainerGroup_UserAssignedIdentity (143.85s)
=== CONT TestAccContainerGroup_linuxBasic
--- PASS: TestAccContainerGroup_logTypeUnset (173.14s)
=== CONT TestAccContainerGroup_imageRegistryCredentialsUpdate
--- PASS: TestAccContainerGroup_UserAssignedIdentityWithVirtualNetwork (331.17s)
=== CONT TestAccContainerGroup_ProbeExec
--- PASS: TestAccContainerGroup_linuxBasic (188.85s)
=== CONT TestAccContainerGroup_SystemAssignedIdentityNoNetwork
--- PASS: TestAccContainerGroup_ProbeExec (135.10s)
=== CONT TestAccContainerGroup_withInitContainer
--- PASS: TestAccContainerGroup_SystemAssignedIdentityNoNetwork (136.86s)
=== CONT TestAccContainerGroup_encryption
--- PASS: TestAccContainerGroup_imageRegistryCredentialsUpdate (217.63s)
=== CONT TestAccContainerGroup_secretVolume
--- PASS: TestAccContainerGroup_withInitContainer (125.43s)
=== CONT TestAccContainerGroup_emptyDirVolumeShared
--- PASS: TestAccContainerGroup_secretVolume (130.87s)
=== CONT TestAccContainerGroup_emptyDirVolumeSharedWithInitContainer
--- PASS: TestAccContainerGroup_emptyDirVolumeShared (134.25s)
=== CONT TestAccContainerGroup_ProbeHttpGet
--- PASS: TestAccContainerGroup_linuxComplete (1320.01s)
=== CONT TestAccContainerGroup_emptyDirVolume
--- PASS: TestAccContainerGroup_emptyDirVolumeSharedWithInitContainer (128.24s)
--- PASS: TestAccContainerGroup_encryption (350.81s)
--- PASS: TestAccContainerGroup_ProbeHttpGet (137.60s)
--- PASS: TestAccContainerGroup_emptyDirVolume (136.39s)
PASS
ok github.com/hashicorp/terraform-provider-azurerm/internal/services/containers 2046.927s
@magodo I have resolved all the points, raised by you.
Removed tests' modifications and now they look good.
Tests TestAccContainerGroup_
are all passed.
@magodo There was a failing check, coming from main branch (not related to this PR). I have fixed it in #18219, so this one should be fine and ready.
@tombuildsstuff This PR has removed network_profile_id
(similar as #17926), shall we move it to the v4 list?
@tombuildsstuff This PR has removed
network_profile_id
(similar as #17926), shall we move it to the v4 list? Seems like #17926 was already merged. Is there any reason for waiting for v4, is it the breaking-change label? If v4 is the target release, what is the timeframe for that (ballpark)? Our current setup with azurerm (3.23.0) provider has issues when changing ACI config and Terraform has to do a destroy and create. That fails for ACI on the private network.
@asbjorn-wiik That PR is then reverted in #18239.
We also have some test failures:
@katbyte I would fix the first one, but the second one is not linked to by changes, just showing that "K80" GPU SKU is not available in EUS2 location. I did expect to have PrimaryLocation being set to "North Europe", where this SKU is available - https://learn.microsoft.com/en-us/azure/container-instances/container-instances-gpu . Not sure what locations are used for running tests in your env.
@katbyte I've updated this one. All tests now complete successfully.
There is a Deprecated
enabled over network_profile_id
.
This functionality has been released in v3.28.0 of the Terraform Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.
For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!
I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active contributions. If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.