tiangolo / uvicorn-gunicorn-fastapi-docker

Docker image with Uvicorn managed by Gunicorn for high-performance FastAPI web applications in Python with performance auto-tuning.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Not able to pass multiple environment variables(BIND & WEB_CONCURRENCY together)

tuner007 opened this issue · comments

docker run -d -p 80:8080 -e BIND="0.0.0.0:8080" myimage works
docker run -d -p 80:80 -e WEB_CONCURRENCY="2" myimage works

I want to do something like -
docker run -d -p 80:8080 -e BIND="0.0.0.0:8080" -e WEB_CONCURRENCY="2" myimage

But when i run this line it actually takes only first variable.

Please let me know how can i send multiple environment variables.

Hmm, not sure what might be happening 🤔 , I just tried it locally and it works as expected:

$ docker run -it -p 80:8080 -e BIND="0.0.0.0:8080" -e WEB_CONCURRENCY="2" tiangolo/uvicorn-gunicorn-fastapi:python3.6

I just updated a lot of things, so if there was a bug somewhere, then it could have been fixed by the recent changes, could you try again?

Hmm, not sure what might be happening , I just tried it locally and it works as expected:

$ docker run -it -p 80:8080 -e BIND="0.0.0.0:8080" -e WEB_CONCURRENCY="2" tiangolo/uvicorn-gunicorn-fastapi:python3.6

I just updated a lot of things, so if there was a bug somewhere, then it could have been fixed by the recent changes, could you try again?

Thanks for the response, will try and let you know.
Also, wanted to check if configuration file to create this docker image ( tiangolo/uvicorn-gunicorn-fastapi ) is available ?

Fast API is fast !! Thanks a lot !! :)