Alpine Base Docker Image for rust-lang/mdBook and catppuccin/mdbook
Alpine base Docker Image for rust-lang/mdBook and catppuccin/mdbook.
Image tag | Base Image | Image size | Notes |
---|---|---|---|
ghcr.io/hydroxycarbamide/mdbook:alpine |
alpine:latest |
29.3MB | GitHub Packages: Minimum image |
ghcr.io/hydroxycarbamide/mdbook:rust-alpine |
rust:alpine |
812MB | GitHub Packages: mdbook test subcommand is available |
Create your docker-compose.yml
like the following.
version: '3'
services:
mdbook:
container_name: mdbook
image: ghcr.io/hydroxycarbamide/mdbook:alpine # Minimum image
# image: hydroxycarbamide/mdbook:rust-alpine # `mdbook test` subcommand is available
stdin_open: true
tty: true
ports:
- 3000:3000
- 3001:3001
volumes:
- ${PWD}:/book
command:
- serve
- --hostname
- '0.0.0.0'
# Run "mdbook serve"
docker-compose up
# Run a command of mdBook
docker-compose run --rm mdbook init
The mdBook Setup GitHub Action is recommended.