I am adding fastapi to docker which has background tasks. When i am trying to build the docker i am getting this error executor failed running [/bin/sh -c chmod +x entrypoint.sh]: exit code: 1 .Command using to build docker image docker build -t onetest . I have tried removing RUN chmod +x entrypoint.shand tried to build build the image but when i run the docker i got this error docker: Error response from daemon: OCI runtime create failed: container_linux.go:380: starting container process caused: exec: "./entrypoint.sh": stat ./entrypoint.sh: no such file or directory: unknown..
entrypoint.sh
#!/bin/bash
gunicorn --worker-tmp-dir /dev/shm -k uvicorn.workers.UvicornWorker app.main:app
Dockerfile
FROM python:3.9-slim
COPY ./requirements.txt ./requirements.txt
RUN pip3 install --no-cache-dir --upgrade -r ./requirements.txt
COPY ./app ./app
COPY ./inputs ./inputs
COPY ./model ./model
COPY ./tests ./tests
COPY ./gunicorn.config.py ./gunicorn.config.py
COPY ./Procfile ./Procfile
EXPOSE 8000
RUN chmod +x entrypoint.sh
CMD [ "./entrypoint.sh" ]