re-add docker network create dbs#9648
Conversation
The code to create the dbs network has a storied past: - added hypothesis#7673 - removed abbe35c - added again c2a4fe7 - removed again eb998e1 when cookiecutter was applied to h but didn't include this code. The docker-compose.yml says this network should be created automatically (although there's a misspelling there, fixed here as a bonus), and without this network, trying to follow the dev environment setup if this network had not already been created results in a cryptic error.
|
Force-pushed to fixup with yet another misspelling (I hadn't noticed the "docker crate network" misspelling was both in the compose file and in an include provided to cookiecutter. Not sure how y'all might want to handle the fix in cookiecutter-- is it OK to include this |
seanh
left a comment
There was a problem hiding this comment.
@bpow Sorry for the long wait. Thanks for this including the history lesson! It looks like docker network create dbs was indeed removed accidentally by the cookiecutter, so let's get this merged.
Not sure how y'all might want to handle the fix in cookiecutter-- is it OK to include this @docker network create dbs there when other projects within h may use it? Because of this, I'll leave making the fix there as "an exercise to the reader".
Yeah I'm not sure. If fixing this in the cookiecutter we would add an "include" that allows projects to inject their own commands before and/or after the default make services commands. But I'm not sure whether adding that include is worthwhile just for this case. This whole dbs network thing is an annoying hack that was added to make our reports system work (https://github.com/hypothesis/report/). In the long-term I'm not sure if I'd rather get rid of it somehow.
For now let's get this merged and we'll deal with the cookiecutter issue later
The code to create the dbs network has a storied past:
The docker-compose.yml says this network should be created automatically (although there's a misspelling there, fixed here as a bonus), and without this network, trying to follow the dev environment setup if this network had not already been created results in a cryptic error.
Of course, the real fix would be to address this in the cookiecutter to prevent this from
being overwritten the next time that might be applied, so I'll make a pull request there, too.