Sign inSign up

matthewfeickert/mermaid-cli

By matthewfeickert

Updated over 5 years ago

Docker image with mermaid JS and mermaid CLI

Image
1

954

matthewfeickert/mermaid-cli repository overview

DEPRECATED

This Docker image is deprecated in favor of the mermaid project supported tool mermaid-js/mermaid-cli and its Docker image.

To get the mermaid-js/mermaid-cli Docker image run

docker pull minlag/mermaid-cli:latest

mermaid-CLI headless Docker image

Docker image with headless mermaid JS and mermaid CLI

Docker Automated build Docker Build Status Docker Pulls download-size number-of-layers

Node.js Installed Dependencies

All node dependencies installed with yarn

Install

Get the image from Docker Hub

docker pull matthewfeickert/mermaid-cli:<tag>

Run

The ENTRYPOINT is mmdc -p /home/node/puppeteer-config.json so you can use the image as a CLI utility via

docker run --rm -v $PWD:/home/node/data matthewfeickert/mermaid-cli:latest -i <input_file.mmd> -o <output_file.ext>

where ext is one of the supported extensions.

To get a listing of all the options just run

docker run --rm matthewfeickert/mermaid-cli:latest

as the Docker image CMD is --help.

$ docker run --rm matthewfeickert/mermaid-cli:latest
Usage: mmdc [options]

Options:
  -V, --version                                   output the version number
  -t, --theme [theme]                             Theme of the chart, could be default, forest, dark or neutral. Optional. Default: default (default: "default")
  -w, --width [width]                             Width of the page. Optional. Default: 800 (default: "800")
  -H, --height [height]                           Height of the page. Optional. Default: 600 (default: "600")
  -i, --input <input>                             Input mermaid file. Required.
  -o, --output [output]                           Output file. It should be either svg, png or pdf. Optional. Default: input + ".svg"
  -b, --backgroundColor [backgroundColor]         Background color. Example: transparent, red, '#F0F0F0'. Optional. Default: white
  -c, --configFile [configFile]                   JSON configuration file for mermaid. Optional
  -C, --cssFile [cssFile]                         CSS file for the page. Optional
  -s, --scale [scale]                             Puppeteer scale factor, default 1. Optional
  -f, --pdfFit                                    Scale PDF to fit chart
  -p --puppeteerConfigFile [puppeteerConfigFile]  JSON configuration file for puppeteer. Optional
  -h, --help                                      display help for command

Tag summary

Content type

Image

Digest

Size

557.7 MB

Last updated

over 5 years ago

docker pull matthewfeickert/mermaid-cli