Creating the documentation site
(Providing documentation the OpenShift way – Part 3)
After preparing the software, now comes the ease part: writing the documentation. Ok, it’s not the easiest part as every developer and system integrator knows.
But generating the documentation pod now is quite easy.
All you need is the git repo containing the documentation and a BuildConfig with the git coordinates of the documentation. The git coordinates are the git URI, the branch name and the contextDir of the documentation. If the documentation is in directory /documentation of your source repo, that’s the contextDir.
The only thing the generator enforces is, that you need to have an index.adoc in the root of your contextDir. It will convert any file named *.adoc inside the contextDir to HTML. And all files within the contextDir are copied to the output container. So images etc. may be transfered, too.
The result is a container containing a webserver and static data to be served. Just run it and you have a standalone static documentation site.
The next part will take care of bundling everything in nice templates for easy use by the delivery projects.
This article is part of the small series:
- Part 1: Providing documentation the OpenShift way
- Part 2: Creating the s2i builder with ASCIIDOC generation software included
- Part 3: Creating the documentation site
- Part 4: Bundling the components for OpenShift