:( Application Error when using docker-compose

Eduard Damiam Londoño García 1 Reputation point
2022-08-04T18:39:10.08+00:00

I am trying to deploy an application on App Service, at first I made some tests using a single container Django app which works fine but to have more security I made a docker-compose with the Django app and a Nginx server, and everything works fine in my computer, but when I deploy it in App service and go to the URL it shows the next message:

":( Application Error
If you are the application administrator, you can access the diagnostic resources."

and when I try to read the logs the only one is "Failed to load container logs: Resource containerlog of type text not found"

any idea how can I resolve the issue or at least debug it?

here is the compose yml

version: '3.8'  
services:  
  web:  
    image: zaito.azurecr.io/backgroundtasks:latest  
    command: uwsgi --http "0.0.0.0:8000" --protocol uwsgi --module zaitoTasksApi.wsgi --master --processes 4 --threads 2   
    volumes:  
      - static_volume:/usr/src/app/static  
      - media_volume:/usr/src/app/media  
    expose:  
      - "8000"  
    networks:  
      - django-network  
  nginx:  
    image: zaito.azurecr.io/nginx:django  
    restart: always  
    volumes:  
      - static_volume:/usr/src/app/static  
      - media_volume:/usr/src/app/media  
    ports:  
      - "80:80"  
    depends_on:  
      - web  
    networks:  
      - django-network  
networks:  
  django-network:  
    name: django-network  
volumes:  
  media_volume:  
  static_volume:  
Azure Container Registry
Azure Container Registry
An Azure service that provides a registry of Docker and Open Container Initiative images.
387 questions
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
6,875 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Ryan Hill 25,666 Reputation points Microsoft Employee
    2022-08-05T17:42:22.39+00:00

    If you're getting :( Application Error message with your image, more than likely the issue the platform didn't find any port responding to HTTP requests. To find out why that is, you can go to Logs under Deployment Center or access the deployment logs. Just make sure you enabled application logging.

    If you find something that you need further assistance with, just comment what logs you see down below.


  2. Eduard Damiam Londoño García 1 Reputation point
    2022-08-09T14:11:05.32+00:00

    After some research I found azure documentation that says

    "Virtual network integration isn't supported for Docker Compose scenarios in App Service. Access restrictions are ignored if a private endpoint is present."

    the Vnet integration is completely necessary so the application can work, so this is probably the problem. looks like what we are trying to do is not possible using app service.

    https://learn.microsoft.com/en-us/azure/app-service/overview-vnet-integration