title: Error Standard_init_linux.go:219: exec user process caused: no such file or directory
body: <p>I'm adding a 'wait for it' shell script to my Django dockerfile. In my local environment all works okay but In a windows 10 machine I have the error below: standard_init_linux.go:219: exec user process caused: no such file or directory.</p>
  <p>entrypoint file.</p>
  <pre><code>#!/bin/sh
  
  set -o errexit
  set -o pipefail
  set -o nounset
  
  if [ -z &quot;${DB_USER}&quot; ]; then
    base_db_image_default_user='root'
    export DB_USER=&quot;${base_db_image_default_user}&quot;
  fi
  export DATABASE_URL=&quot;jdbc:mysql//${DB_USER}:${DB_PASSWORD}@${DB_HOST}:${DB_PORT}/${DB_NAME}&quot;
  
  mysql_ready() {
    python &lt;&lt;END
  import sys
  import MySQLdb
  
  try:
      MySQLdb.connect(
        host=&quot;${DB_HOST}&quot;,
        user=&quot;${DB_USER}&quot;,
        passwd=&quot;${DB_PASSWORD}&quot;,
        db=&quot;${DB_NAME}&quot;,
        port=${DB_PORT},
      )
  except MySQLdb.OperationalError:
      sys.exit(-1)
  
  sys.exit(0)
  END
  }
  until mysql_ready; do
    echo &gt;&amp;2 'Waiting MYSQL to become available...'
    sleep 1
  done
  
  echo &gt;&amp;2 'MYSQL is available'
  
  exec &quot;$@&quot;
  </code></pre>
  <p>Dockerfile.</p>
  <pre><code>FROM python:3.7-alpine
  ENV PYTHONUNBUFFERED 1
  RUN mkdir /code
  WORKDIR /code
  
  ADD requirements.txt /code/
  RUN apk add --update \
      python3 \
      python3-dev \
      gcc \
      py-pip \
      build-base \
      git \
      wget \
      libxslt-dev \
      xmlsec-dev \
      mariadb-dev \
      libressl-dev \
      libffi \
      cairo-dev \
      pango-dev \
      gdk-pixbuf \
      jpeg-dev \
      zlib-dev \
      freetype-dev \
      lcms2-dev \
      openjpeg-dev \
      tiff-dev \
      tk-dev \
      tcl-dev \
      fontconfig \
      ttf-dejavu
  
  RUN pip3 install -r requirements.txt
  ADD . /code/
  
  ARG DJANGO_APP
  ENV DJANGO_APP=${DJANGO_APP}
  EXPOSE 8000
  
  RUN sed -i 's/\r//' /code/compose/local/django/entrypoint
  RUN chmod +x /code/compose/local/django/entrypoint
  
  ENTRYPOINT [&quot;/code/compose/local/django/entrypoint&quot;]
  #CMD [&quot;sh&quot;, &quot;-c&quot;, &quot;gunicorn --bind 0.0.0.0:8000 ${DJANGO_APP}.wsgi:application&quot;]
  </code></pre>
  <p>docker-compose.yml</p>
  <pre><code>version: '3'
  services:
    web:
      image: cannon-oms:latest
      command: python manage.py runserver 0.0.0.0:8000
      volumes:
        - .:/code
      ports:
        - &quot;8000:8000&quot;
      expose:
        - &quot;8000&quot;
      depends_on:
        - db
        - redis
        - rabbit-mq
      env_file:
        - .env
      
    worker:
      image: cannon-oms:latest
      command: celery -A main worker -B -l info --loglevel=info
      volumes:
        - .:/code
      depends_on:
        - rabbit-mq
        - db
        - redis
        - web
      env_file:
        - .env
  
    redis:
      image: redis
      ports:
        - &quot;6379:6379&quot;
      networks:
        - django-oms
  
    db:
      image: mysql/mysql-server:5.7
      ports:
        - &quot;3306:3306&quot;
      environment:
        MYSQL_DATABASE: db
        MYSQL_USER: dbuser
        MYSQL_PASSWORD: passworddb
        MYSQL_ROOT_PASSWORD: passworddb
      volumes:
        - .:/code
      networks:
        - django-oms
      
    rabbit-mq:
      image: &quot;rabbitmq:3-management&quot;
      environment:
        RABBITMQ_DEFAULT_USER: conejomq
        RABBITMQ_DEFAULT_PASS: badbunny
  
      
  </code></pre>
  <p>Thank you very much.</p>