I have a Python (2.7) app which is started in my dockerfile:
CMD [\"python\",\"main.py\"]
main.py prints some strings when it is s
You can see logs on detached image if you change print to logging.
print
logging
main.py:
import time import logging print "App started" logging.warning("Log app started") while True: time.sleep(1)
Dockerfile:
FROM python:2.7-stretch ADD . /app WORKDIR /app CMD ["python","main.py"]