Closed znmeb closed 6 years ago
I agree documenting the pattern will help. We may want to look at a reactor as well, as discussed in pull request #14
Does the Django code retry connecting? It's possibly trying to connect before the PostgreSQL container is ready.
'Depends_on' only waits for container to be running, not that it is ready. Was looking at this a bit earlier today:
https://docs.docker.com/compose/startup-order/
@kiniadit had some new comments in slack so lets see at meeting whether this is actually the issue or still env variables.
incorporating a wait-for-it type script maybe something we pursue still though, so will open an issue.
I think we identified that cause of this, while we have the question of the ideal startup, would we consider this issue still open?
If it's working, close it!
I'm pretty sure this is just a documentation / environment variable problem; I can connect manually from the command line in the Django container using
psql
.