rtfd/readthedocs.org — pull request #1020 by agjohnson (2014-11-08 08:14:28+00:00)
Title:  Modularize, clean up, and test docker build environments 

This modularizes the docker build commands into an environment class to track the state of the version passed in. Eventually, this will allow for reporting against the version instance on a per-command basis.

This drops `build.json` output to pass in json on stdin/stdout when calling the docker run management command. Docker configuration of django settings is now done with a separate settings file, which allows for override by environment variables via any variable with the prefix `RTD_DOCKER_`. This allows for configuration of django inside docker without a customized docker build for every environment.

Some supporting changes include API serializers that return all instance fields and removing api access to the sphinx context backend. The management command was altered to expect a file or stdin, as we use it, via `fileinput`. Exceptions are caught generically on the management command and reported, so theoretically, errors with the docker environment or during setup will also be caught and reported on the build status page.