Docker support #1
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This adds support for a docker based development environment.
After you've added your config to
docker.env,docker-compose upshould start up MongoDB and Redis and get the gridspree app running under HTTPS with a self-signed cert and code changes causing an automatic app reload. The first run will take a while since it will have to fetch the redis and mongo images and build the python env for gridspree. After that it should be fairly quick.I've only tested this on Ubuntu. I'd be interested on feedback running on non-Linux platforms. It should work fine but you will need to use a different IP in
docker.envas the docker daemon will be running inside a VM on those platforms.I had to add some code to
main/__init__.pyto get the app to wait unitl MongoDB and Redis are ready since the app fails with a fatal error if it gets further than this and can't connect to MongoDB. I don't think this should cause any problems when running in other environments.