Skip to content

Latest commit

 

History

History
61 lines (38 loc) · 1.2 KB

README.md

File metadata and controls

61 lines (38 loc) · 1.2 KB

Dockerized mkdocs

dockerized mkdocs

Getting started

See: https://www.mkdocs.org/getting-started/

Installation

You can skip this step.

Creating a new Project

dockerized mkdocs new my-project

Serving

The mkdocs serve command needs some adjustment to work with dockerized:

dockerized -p 8000 mkdocs serve --dev-addr=0.0.0.0:8000
  • -p 8000 — Tells dockerized to forward port 8000 from the host to the container.
  • --dev-addr=0.0.0.0:8000 — Tells mkdocs to listen on all interfaces on port 8000.

You can now access the live site at http://localhost:8000.

Mkdocs plugins

See:

By default, the following plugins are installed:

  • mkdocs-material
  • mkdocs-material-extensions

To install more plugins:

  • Add their pip package name to the MKDOCS_PACKAGES environment variable.

    # dockerized.env
    MKDOCS_PACKAGES="${MKDOCS_PACKAGES} mdx-truly-sane-lists"

    Rebuild mkdocs:

    dockerized --build mkdocs
  • Follow the other instructions in the plugin's documentation.