Commit e72c2e0
fix: replace azurerm_container_app_custom_domain with az rest PATCH for cert binding
azurerm_container_app_custom_domain rejects managedCertificate IDs at plan
time (expects .../certificates/... but managed certs use
.../managedCertificates/...). This is a known AzureRM provider limitation.
Replace with a null_resource that PATCHes the container app ingress directly
via az rest. The PATCH reads the current ingress config (GET), updates
customDomains to SniEnabled with the managed cert ID, and writes it back.
This bypasses the provider's ID-format validation entirely.
Execution order:
1. null_resource.hostname_registration - az hostname add (Disabled)
2. azurerm_...managed_certificate - cert provisioned
3. null_resource.cert_binding - az rest PATCH to SniEnabled
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent 88380ab commit e72c2e0
1 file changed
Lines changed: 32 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
221 | 221 | | |
222 | 222 | | |
223 | 223 | | |
224 | | - | |
225 | | - | |
226 | | - | |
227 | | - | |
228 | | - | |
229 | | - | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
230 | 256 | | |
231 | 257 | | |
232 | 258 | | |
0 commit comments