Docs Builder

A set of common tools to build documentation sites for plugins
Alternatives To Docs Builder
Project NameStarsDownloadsRepos Using ThisPackages Using ThisMost Recent CommitTotal ReleasesLatest ReleaseOpen IssuesLicenseLanguage
Docker5,795
7 days ago40mitDockerfile
Docker official jenkins repo
Blueocean Plugin2,8492577 days ago400February 26, 201969mitJava
Blue Ocean is a reboot of the Jenkins CI/CD User Experience
Configuration As Code Plugin2,513
a day ago92mitJava
Jenkins Configuration as Code Plugin
Kubernetes Plugin2,1703014 days ago12February 17, 201721apache-2.0Java
Jenkins plugin to run dynamic agents in a Kubernetes/Docker environment
Pipeline Plugin1,7176745a year ago76March 03, 20176
Obsolete home for Pipeline plugins
Gitlab Plugin1,410
15 hours ago227gpl-2.0Java
A Jenkins plugin for interfacing with GitLab
Jenkinsfile Runner1,003
a month ago86mitJava
A command line tool to run Jenkinsfile as a function
Ansible Role Jenkins778
4 months ago10mitGroovy
Ansible Role - Jenkins CI
Slack Plugin661
107 days ago8March 11, 201782Java
A Jenkins plugin for posting notifications to a Slack channel
Ghprb Plugin480
9a year ago110April 14, 2017185mitJava
github pull requests builder plugin for Jenkins
Alternatives To Docs Builder
Select To Compare


Alternative Project Comparisons
Readme

CakePHP Plugin Docs Builder

This repository provides common tools for building documentation sites for plugins maintained by the CakePHP team. This build tooling is not meant for community plugins.

Building docs with these tools

To use these tools your plugin should create a docker image based on markstory/cakephp-docs-builder. It should add your plugin's docs to /data/docs and then use the tools provided in the base image to build the site using sphinx. An example of this is:

# Generate the HTML output.
FROM markstory/cakephp-docs-builder as builder

COPY docs /data/docs

RUN cd /data/docs-builder && \
  # In the future repeat website for each version
  make website SOURCE=/data/docs DEST=/data/website/1.1


# Build a small nginx container with just the static site in it.
FROM nginx:1.15-alpine

COPY --from=builder /data/website /data/website
COPY --from=builder /data/docs-builder/nginx.conf /etc/nginx/conf.d/default.conf

# Move each version into place
RUN mv /data/website/1.1/html/ /usr/share/nginx/html/1.1

Your plugin's docs will need to define a minimal sphinx configuration. You'll need at least the following:

  • An index.rst that builds a toctree for all documents.
  • A conf.py file that configures sphinx.

An example conf.py is as follows:

# Global configuration information used across all the
# translations of documentation.
#
# Import the base theme configuration
from cakephpsphinx.config.all import *

# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
#

# The full version, including alpha/beta/rc tags.
release = '1.1'

# The search index version. This needs to match
# the INDEX_PREFIX variable used when `make populate-index` is called.
search_version = 'authorization-11'

# The marketing display name for the book.
version_name = ''

# Project name shown in the black header bar
project = 'CakePHP Authorization'

# Other versions that display in the version picker menu.
version_list = [
    {'name': '1.1', 'number': '1.1', 'title': '1.1.x', 'current': True},
]

# Languages available.
languages = ['en']

# The GitHub branch name for this version of the docs
# for edit links to point at.
branch = 'master'

# Current version being built
version = '1.1'

# Language in use for this directory.
language = 'en'

What these tools build

After defining a docker file for your plugin you and building the image, you'll get the following:

  • A static HTML site built with sphinx, using the cakephp-sphinxtheme
  • Nginx serving out of /var/www/html.
  • Dokku configuration for re-indexing content after the app starts up.

Adding a translation to a plugin's docs

The languages offered by a plugin are stored in a few places and each needs to be updated separately:

  • The conf.py file contains a languages list.
  • Each translation needs to set language in its configuration file.
  • The docs.Dockerfile in your plugin needs to pass LANGS to each make task in docs-builder that is called.
  • You need to update the jenkins deploy scripts in this repository to pass LANGS when rebuilding elasticsearch indexes.
  • Update build jobs in jenkins.

Pushing update of this project's docker image

When you make changes to either cakephp/cakephpsphinx or this repository you need to publish a new docker image and update the cakephp server.

First get a personal access token that has write:packages and read:packages scopes. The login to the container registry:

export CR_PAT=<token>
echo $CR_PAT | docker login ghcr.io -u USERNAME --password-stdin

Now build images and push them:

docker build -t ghcr.io/cakephp/docs-builder .
docker push ghcr.io/cakephp/docs-builder
docker build -t ghcr.io/cakephp/docs-builder:runtime -f runtime.Dockerfile .
docker push ghcr.io/cakephp/docs-builder:runtime

Plugins will use the new base image when they next have their docs deployed.

Popular Plugin Projects
Popular Jenkins Projects
Popular Libraries Categories

Get A Weekly Email With Trending Projects For These Categories
No Spam. Unsubscribe easily at any time.
Php
Plugin
Jenkins
Cakephp
Sphinx