2013-03-26 07:48:04 +04:00
|
|
|
Docker documentation and website
|
|
|
|
================================
|
2013-03-22 08:47:14 +04:00
|
|
|
|
2013-03-26 07:48:04 +04:00
|
|
|
Documentation
|
|
|
|
-------------
|
|
|
|
This is your definite place to contribute to the docker documentation. The documentation is generated from the
|
|
|
|
.rst files under sources.
|
2013-03-26 06:52:52 +04:00
|
|
|
|
2013-03-26 07:48:04 +04:00
|
|
|
The folder also contains the other files to create the http://docker.io website, but you can generally ignore
|
|
|
|
most of those.
|
|
|
|
|
|
|
|
|
|
|
|
Installation
|
2013-03-26 06:52:52 +04:00
|
|
|
------------
|
|
|
|
|
2013-03-26 07:48:04 +04:00
|
|
|
* Work in your own fork of the code, we accept pull requests.
|
2013-06-02 08:26:18 +04:00
|
|
|
* Install sphinx: `pip install sphinx`
|
|
|
|
* Mac OS X: `[sudo] pip-2.7 install sphinx`)
|
|
|
|
* Install sphinx httpdomain contrib package: `pip install sphinxcontrib-httpdomain`
|
|
|
|
* Mac OS X: `[sudo] pip-2.7 install sphinxcontrib-httpdomain`
|
2013-03-26 07:48:04 +04:00
|
|
|
* If pip is not available you can probably install it using your favorite package manager as **python-pip**
|
2013-03-26 06:52:52 +04:00
|
|
|
|
|
|
|
Usage
|
|
|
|
-----
|
|
|
|
* change the .rst files with your favorite editor to your liking
|
2013-03-26 07:48:04 +04:00
|
|
|
* run *make docs* to clean up old files and generate new ones
|
|
|
|
* your static website can now be found in the _build dir
|
2013-06-02 08:25:51 +04:00
|
|
|
* to preview what you have generated run `make server` and open <http://localhost:8000/> in your favorite browser.
|
2013-03-26 07:48:04 +04:00
|
|
|
|
|
|
|
Working using github's file editor
|
|
|
|
----------------------------------
|
|
|
|
Alternatively, for small changes and typo's you might want to use github's built in file editor. It allows
|
|
|
|
you to preview your changes right online. Just be carefull not to create many commits.
|
|
|
|
|
|
|
|
Images
|
|
|
|
------
|
|
|
|
When you need to add images, try to make them as small as possible (e.g. as gif).
|
2013-03-26 06:52:52 +04:00
|
|
|
|
|
|
|
|
|
|
|
Notes
|
|
|
|
-----
|
2013-03-26 07:48:04 +04:00
|
|
|
* The index.html and gettingstarted.html files are copied from the source dir to the output dir without modification.
|
|
|
|
So changes to those pages should be made directly in html
|
|
|
|
* For the template the css is compiled from less. When changes are needed they can be compiled using
|
2013-04-09 07:10:47 +04:00
|
|
|
lessc ``lessc main.less`` or watched using watch-lessc ``watch-lessc -i main.less -o main.css``
|
|
|
|
|
|
|
|
|
|
|
|
Guides on using sphinx
|
|
|
|
----------------------
|
|
|
|
* To make links to certain pages create a link target like so:
|
|
|
|
|
|
|
|
```
|
|
|
|
.. _hello_world:
|
|
|
|
|
|
|
|
Hello world
|
|
|
|
===========
|
|
|
|
|
|
|
|
This is.. (etc.)
|
|
|
|
```
|
|
|
|
|
|
|
|
The ``_hello_world:`` will make it possible to link to this position (page and marker) from all other pages.
|
|
|
|
|
|
|
|
* Notes, warnings and alarms
|
|
|
|
|
|
|
|
```
|
|
|
|
# a note (use when something is important)
|
|
|
|
.. note::
|
|
|
|
|
|
|
|
# a warning (orange)
|
|
|
|
.. warning::
|
|
|
|
|
|
|
|
# danger (red, use sparsely)
|
|
|
|
.. danger::
|
|
|
|
|
|
|
|
* Code examples
|
|
|
|
|
|
|
|
Start without $, so it's easy to copy and paste.
|