autogen icon indicating copy to clipboard operation
autogen copied to clipboard

[Issue]: Unable to Access AutoGenStudio(running in docker sharing the host network) on Port 8081 from Host Despite --network host Option

Open new4u opened this issue 11 months ago • 1 comments

Describe the issue

I'm encountering an issue with accessing AutoGenStudio running inside a Docker container from the host machine. The container is started with the --network host option, which should allow for direct access to the service on the host's network interface, but it seems that the service is only listening on 127.0.0.1:8081 instead of 0.0.0.0:8081.

Steps to reproduce

Created a Dockerfile with the following content:

FROM python:3.11-slim
RUN pip install autogenstudio
EXPOSE 8081
CMD ["autogenstudio", "ui", "--port", "8081"]

Built the Docker image with the command:

docker build -t autogenstudio .

Ran the container using:

docker run -d --name autogenstudio --network host autogenstudio

Attempted to access the UI via http://localhost:8081 from the host machine without success.

Screenshots and logs

image

Additional Information

version are up to date

I suspect that the service needs to be configured to listen on 0.0.0.0 instead of 127.0.0.1, but I haven't found a way to make this adjustment for AutoGenStudio. Any guidance or suggestions on how to properly configure the service to listen on all interfaces would be greatly appreciated.

Thank you for your assistance!

new4u avatar Mar 19 '24 08:03 new4u