Search code examples
azurecontainersazure-container-instancesazure-container-apps

ContainerApp ingress internal with VNet not accessible


I've created a simple hello world container app with an internal ingress but it doesn't work accessing it using the same VNet with a separate VM on it -- it's just inacessible. Any idea what is going wrong? It should work as follows:

  • Container Apps should NOT be publicly accessible through the internet
  • Container Apps should work INTERNAL only within the network
  • Container Apps should be accessible through the VNET

I configured it as follows:

ContainerApp

  • Container App: ca-dev
  • Container App Name: containerapp-1
  • Deployment source: Container Image
  • Region: North Europe
  • Container App Environment: managedEnvironment-cadev-8098 (ca-dev)
  • QuickStart Image: Simple hello world container

Ingress Application ingress settings:

  • Ingress: Enabled
  • Ingress Traffic: Accept traffic from anywhere
  • Target Port: 80

Managed Environment

  • managedEnvironment-cadev-8098 (ca-dev)
  • Public Network Access: Disable
  • Virtual Network: me-dev
  • VNET Address Block: 10.0.0.0/16
  • Subnet Name: someSubnet
  • Subnet: 10.0.0.0/16
  • Virtual IP: Internal
  • Infrastructure resource group: ca-infra
  • Enable Private Endpoints: Yes
  • Private Endpoint Name: somePE
  • Private endpoint virtual network: sql-dev
  • DNS: Azure Private DNS Zone

Solution

  • ContainerApp ingress internal with VNet not accessible

    Ingress Traffic: Accept traffic from anywhere

    "As you mentioned Ingress Traffic, you selected Accept traffic from anywhere, but this is for external access. In order to access within the VNet, make sure to select the Limited to VNet option under ingress settings. Follow the MS Doc for more details

    enter image description here

    Contianer app ingress settings

    enter image description here

    Note: You can also check the NSG rules to see if any Deny rule has been created for outbound traffic on ports 80 and 443.

    Private DNS Zone configuration

    enter image description here

    Private endpoint configuration

    enter image description here

    When I try to access the container app from the VM, the container app is able to access it.

    enter image description here

    Result from outside network.

    enter image description here

    Follow Stack Link1 and Stack Link 2. for the same realted issue.

    Ingress settings