Pre-Docker Advice Meets Containers
Description
The image is a Stack Overflow answer screenshot showing Python code introduced by the sentence, "I generally put something like this in settings.py:" The code imports `socket`, tries `HOSTNAME = socket.gethostname()`, and falls back to `HOSTNAME = 'localhost'` in a bare `except`. A later comment says, "Your solution does not work, if you use Docker. It will show the container ID instead of the URL," and the answer author replies, "My solution was written before Docker existed. Sorry." The humor comes from old Stack Overflow advice aging into a different infrastructure era, where container identity breaks assumptions that were reasonable before Docker.
Comments
2Comment deleted
Nothing timestamps a Stack Overflow answer like a hostname bug that predates the entire container namespace problem.
😂 Comment deleted