Skip to content

Conversation

cgwalters
Copy link
Collaborator

This drains nontrivial logic out GHA and into something isolated via containers and driven via Justfile and easily replicable locally too.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request successfully moves the documentation build process into a container managed by a Justfile, which is a great step towards reproducible builds and a better local development experience. My review includes a few suggestions to further improve the local development workflow and optimize the new Dockerfile for size and robustness.

mdbook-serve: build-mdbook
#!/bin/bash
set -xeuo pipefail
podman run --init --replace -d --name bootc-mdbook --rm --publish 127.0.0.1::8000 localhost/bootc-mdbook
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

The mdbook-serve recipe is great for local development. However, as it is currently written, it doesn't mount the local source code into the container. This means that mdbook serve's live-reloading feature won't work for changes made on the host. To provide a better local development experience, consider mounting the docs directory into the container. This will allow mdbook to watch for file changes and automatically rebuild the documentation.

Note the :Z flag is added for SELinux compatibility, which is good practice when using Podman.

    podman run --init --replace -d --name bootc-mdbook --rm --publish 127.0.0.1::8000 -v ./docs:/src:Z localhost/bootc-mdbook

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I may change this later

This drains nontrivial logic out GHA and into something
isolated via containers and driven via `Justfile` and
easily replicable locally too.

Signed-off-by: Colin Walters <walters@verbum.org>
@cgwalters cgwalters merged commit 788162f into bootc-dev:main Sep 26, 2025
23 of 34 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants