Open kamalsivalingam opened 1 month ago
@kamalsivalingam Hi, Yes, if you have multiple Azure Container Environments, each with its own MongoDB instances, it's possible for other container apps to reference them by the name 'mongo'. -- In Azure Container Service (ACS), there is a feature called appname that functions similarly to Docker Composes network alias.
Thanks @v-vish. If i have multiple container app environments, the name of the container app should be unique across all the environments. So do i have to suffix with something like environment name? Once i suffix and make the name unique, can i access the db container app from other container app using the name?
You're application name does not have to be unique across all environments. You can use the same name over and over as long as it's not within the same environment. Are you wanting to connect from one environment to another one which hosts your DB?
@simonjj Looks like the container app name should be unique across container environments not just within. I get below error when i try to use the same name in a different environment... (ContainerAppEnvironmentMismatch) Container App 'gw-pr-303' already exists in a different environment. To create it in the environment '/subscriptions/xxx-xxx-xxx/resourceGroups/xx-xx-xx/providers/Microsoft.App/managedEnvironments/pr-304' delete it from the environment 'pr-303' first.
This issue is a: (mark with an x)
Issue description
This is rather a question.. How do we implement network aliases within Azure Container Environment. While docker compose supports network aliases, if we feed the docker compose, does Azure Container Apps use the network alias?
For example, I have multiple azure container environments each of them having its own mongo db instances that needs to be referenced by name "mongo" by other container apps. i can not have the service name as mongo in every environment as Azure Container Environment is requiring the service names to be globally unique. How to achieve local dns resolution within azure container environment so that the name "mongo" resolves to the local instance within the container environment?
Steps to reproduce
Expected behavior [What you expected to happen.]
Actual behavior [What actually happened.]
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Ex. Did this issue occur in the CLI or the Portal?