Docker and CI/CD · Middle · Question 22 of 75
Why should containers log to stdout and stderr?
- 1Writing log files inside containers is not allowed
- ✓Correct answer: The platform collects and routes the streams for you
- 3stdout is faster than any other way of logging
Explanation
Log files inside a container fill its writable layer and vanish with it. Twelve-factor apps treat logs as event streams; the platform ships them to a log store.