You can view the output of your application (for example, django logs) in real time by setting PYTHONUNBUFFERED to a non-empty value other than 0, which will cause the python output, i.e. the stdout and stderr streams, to be sent directly to terminal (for example, your container log) without being first buffered.
|
|
Settings PYTHONUNBUFFERED to 1 prevents any unwritten partial output from being held in a buffer in the event that the python application terminates unexpectedly.