Building and Deploying the MongoDB Documentation
This document contains more direct instructions for building the MongoDB documentation.
- GNU Make
- Sphinx (documentation management)
- Pygments (syntax highlighting)
- LaTeX/PDF LaTeX (typically texlive; for building PDFs)
- Common Utilities (rsync, tar, gzip, sed)
Building the Documentation
Clone the repository:
git clone git://github.com/mongodb/docs.git
Install dependencies. The TeX/LaTeX dependency is very large, but is
only required if building the PDF edition, or building for production
See above for list. On Arch Linux, use the following command to install the full dependencies:
pacman -S texlive-bin texlive-core texlive-latexextra python2-sphinx python2-pygments
On Debian/Ubuntu systems use the following command:
apt-get install python-sphinx texlive-latex-recommended texlive-latex-recommended
Note: The Debian/Ubuntu dependencies, have not been thoroughly tested. If you find an additional dependency, please submit a pull request to modify this document.
On OS X:
You may need to use
pipusing the following command if you have not already done so:
Alternately, you may be able to replace
easy_installin the next step.
Install Sphinx, Docutils, and their dependencies with
pipusing the following command:
pip install Sphinx Jinja2 Pygments docutils
docutilsare all dependencies of
As of June 6, 2012 and Sphinx version 1.1.3, you must compile the MongoDB documentation using the Python 2.x series version of Sphinx. There are serious generation problems with the Python 3 series version of Sphinx.
Install a TeX distribution (for building the PDF.) If you do not have a LaTeX installation, use MacTeX
If you have any corrections to the instructions for these platforms or you have a dependency list for Fedora, CentOS, Red Hat, or other related distributions, please submit a pull request to add this information to this document.
To build a test version of the Manual, issue the following command:
This places a complete version of the manual in
../public-docs/" named for the current branch (as of
2012-03-19, typically master.)
To publish a new build of the manual, issue the following command:
Warning: This target depends on
publish, and simply uses
rsync to move the content of the "
../public-docs/" to the web
servers. You must have the proper credentials to run these operations.
publish procedure and thoroughly test the build before pushing
To build a quick demo build for viewing the documentation locally and testing features of the documentation, use the following target:
This places a simple build of the HTML content of the manual in
If you encounter problems with the build, please contact the docs team, so that we can update this guide and/or fix the build process.