2016-05-27 01:58:42 -05:00
|
|
|
# Building The Docs
|
2015-03-12 14:19:59 -05:00
|
|
|
|
2016-05-27 01:58:42 -05:00
|
|
|
To build the docs locally, you need to have docker installed. The
|
|
|
|
docs are built using a custom [docker](https://www.docker.com/) image
|
|
|
|
and the [mkdocs](http://www.mkdocs.org/) tool.
|
|
|
|
|
|
|
|
**Prepare the Docker Image**:
|
|
|
|
|
2017-02-06 03:19:47 -06:00
|
|
|
Git clone `grafana/grafana.org` repo. Run these commands in the root of that repo. **Note** that you may require ``sudo``
|
2016-05-27 01:58:42 -05:00
|
|
|
when running ``make docs-build`` depending on how your system's docker
|
|
|
|
service is configured):
|
2015-03-12 14:19:59 -05:00
|
|
|
|
|
|
|
```
|
2017-02-06 03:19:47 -06:00
|
|
|
$ git clone https://github.com/grafana/grafana.org
|
|
|
|
$ cd grafana.org
|
2015-03-12 14:19:59 -05:00
|
|
|
$ make docs-build
|
|
|
|
```
|
|
|
|
|
2016-05-27 01:58:42 -05:00
|
|
|
**Build the Documentation**:
|
|
|
|
|
|
|
|
Now that the docker image has been prepared we can build the
|
|
|
|
docs. Switch your working directory back to the directory this file
|
|
|
|
(README.md) is in and run (possibly with ``sudo``):
|
|
|
|
|
2015-03-12 14:19:59 -05:00
|
|
|
```
|
|
|
|
$ make docs
|
|
|
|
```
|
|
|
|
|
2016-05-27 01:58:42 -05:00
|
|
|
This command will not return control of the shell to the user. Instead
|
|
|
|
the command is now running a new docker container built from the image
|
|
|
|
we created in the previous step.
|
|
|
|
|
2017-02-06 03:19:47 -06:00
|
|
|
Open [localhost:3004](http://localhost:3004) to view the docs.
|
2016-05-27 01:58:42 -05:00
|
|
|
|
|
|
|
|