-
Notifications
You must be signed in to change notification settings - Fork 30
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
Using Bicep to deploy removes manually configured domain #957
Comments
+1 on this |
Struggled with the same issue. Unfortunately setting shell script workaround:
|
Hi - we are working on simplifying the Managed Certificate creation process so that certificates and apps can be created in a single bicep template: https://stackoverflow.com/questions/76919608/azure-container-app-managed-certificates-deployed-using-bicep We haven't made as much progress as we would have liked, but we are picking this up now. We should have a good ETA for this improvement in the coming weeks. |
thank you! really looking forward to this |
Any update on this? |
Just want to bump this. I've spent the past 3 days templatizing my azure resources in bicep, and cannot deploy changes to my resources because my custom domain mapping (which I had to add by hand to get around the managed cert shortcoming), gets wiped away. So, now if i run my bicep deployment, I break my prod environment. I've looked all around for some workarounds to this, and haven't found anything for a managed cert, so I'm left w the decision to either bring (and subsequently manage) my own certs, or let all my work on this bicep template be for nothing. That is not a fun decision to have to make. |
I am also experiencing the same problem. I did try "two" step deployment following guide suggested above. However it does not work as creation of managed certificate on the container environment gets stuck in "Pending" State. The only difference is that i am doing domain validation on "TXT". However looking at the deployment status it is accepted but as mentioned above gets stick in Pending state.
|
Any updates please , this is very frustrating that we have to reconfigure the custom domain after a deployment |
I was able to get this working by having a 2 step setup process where I can disable the certifications logic via a flag as well as pass in the manually created certificate details via an array. @description('Array of custom domains e.g. subdomain.domain.com which will be configured for the app.')
param appCustomDomainsNames array = []
param createManagedCerts bool All of the container app logic is in a module and the caller essentially runs it twice. Once with the flag and once without. The first time it runs, the second invocation fails because no certificates have been created. However, container app will still be created. From here I manually create the certificate / custom domains and verify. This gives me a certificate name that I can then update the calling param with. I check this into our source control and from here on out the deployments all go smoothly. Kind of a pain in the butt to the first deployment working but it works just fine after that. param appCustomDomainsNames = [
{
domain: 'myapp.my-domain.com'
certificateName: 'generated certificate name from manual creation'
}
] |
@vinisoto Any update on this? |
Still not completed? Any ETA |
Can you share any information on progress? |
This issue is a: (mark with an x)
Issue description
When deploying Microsoft.App/containerApps@2023-05-01 using bicep and New-AzResourceGroupDeployment a previously manually set custom domain is removed.
Steps to reproduce
Expected behavior [What you expected to happen.]
customDomains
do not remove the assigned domaincustomDomains
to an empty array remove the assigned domainActual behavior [What actually happened.]
If the ingress definition has not set
customDomains
assigned domain is removedScreenshots
n.a.
Additional context
Other Azure Resources like Static Websites do not remove custom domain when re-deploying.
The proposed behavior would make it easy for people with small deployments to use managed certificates without setting up a complicated automated verification process (#796, #607). This issue is only about enabling the simple case of manually configuing the custom domain in the portal on top of an otherwise automated deployment.
The text was updated successfully, but these errors were encountered: