Docker logging while running Streamlit

Hi, I’ve managed to get Streamlit to successfully run within a Docker container. My script prints out certain things when certain operations are performed (e.g. fetching data).

I know that if you run python some_script.py the stdout goes to the Docker log file. Is there some way to get the same behaviour with streamlit run my_app.py? At the moment the log is empty.

Edit: the exact command to run my app is this:
ENTRYPOINT ["conda", "run", "-n", "my_env", "streamlit", "run", "src/streamlit_app.py"]

Hello,
same here.

I’ve tried CMD ["conda run -n img streamlit run /img/app/app.py > app.log"] but no success…

When running on a sever/container it’s advisable to use logging. Here’s useful summaries:

Details here:
https://docs.python.org/3/howto/logging.html