-
Notifications
You must be signed in to change notification settings - Fork 705
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
APIM - use existing pip #1960
APIM - use existing pip #1960
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hi @mark-gronow thanks for your PR!
As Terraform is lazy at plan-time to evaluate the value with try statements, the public_ip_address_id
as it is wouldnt be assesed at plan time. Meaning if you add a public ip address, even if not related to config file, it would create a "known at apply" message which could make ops teams anxious, as showed here: #1952 (review) . Do you think we could modify the statement in the same shape as described in the other PR? (a-la: disk_encryption_set_id = can(each.value.os_disk.disk_encryption_set_id) ? each.value.os_disk.disk_encryption_set_id : can(each.value.os_disk.disk_encryption_set_key) ? var.disk_encryption_sets[try(each.value.os_disk.lz_key, var.client_config.landingzone_key)][each.value.os_disk.disk_encryption_set_key].id : null)
Can you please also check your example file for:
- The right resource group keys.
- The right vnet and subnet address space blocks.
- Resource group for the NSG.
- Remove the nsg flow logs since your example does not have diagnostics.
Closing this as updated in #1971 - thanks for the PR @mark-gronow |
* apm - use existing pip * add to long runner integration test * Refactor API Management module and example Refactor API Management module and update example configuration for better clarity and functionality. - Modify the `public_ip_address_id` assignment in `modules/apim/api_management/module.tf` to use `can` statements for conditional checks, enhancing clarity and reducing potential confusion during plan-time evaluation. - Update the example configuration in `examples/apim/118-api_management_platform_stv2/configuration.tfvars` to correct resource group keys, vnet and subnet address spaces, ensuring they align with task requirements. - Remove NSG flow logs configurations from the example file to simplify the setup and adhere to the task's request for removal. --- For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/aztfmod/terraform-azurerm-caf/pull/1960?shareId=73fef528-9148-4db9-8557-478779a850ce). * Update module.tf * Update to use public_ip_address --------- Co-authored-by: mark.gronow@shapingcloud.com <mark.gronow@shapingcloud.com>
PR Checklist
Description
APIM does not currently support using an existing Public IP, which is required for deployment/upgrade of the APIM Platform to version stv2.*. stv1 is going EOL 2025. This PR adds support for using a Public IP in the APIM module.
Does this introduce a breaking change
Testing
Run example examples/apim/118-api_management_platform_stv2/configuration.tfvars
I was able to successfully deploy it in my testing.