doc: docs tooling and configuration updates#1368
doc: docs tooling and configuration updates#1368minaelee wants to merge 19 commits intocanonical:mainfrom
Conversation
ba13e3d to
dbab7ca
Compare
50ceb07 to
09eeff4
Compare
c38ed10 to
f7a14df
Compare
91dd5e2 to
90f9f10
Compare
|
Note: RTD build has been failing for the past hour. I tried to debug it but nothing helped, and then I thought to check other projects with recent RTD builds, and it looks like every build within the past hour on RTD has failed. Could be a GitHub issue or RTD issue. Either way, I'll wait to see if it is resolved in the morning. |
Also the link checks are quite unstable over the last days, lots of timeouts. Likely related to the recent issues? |
There was a problem hiding this comment.
Pull request overview
This PR updates MicroCloud’s documentation toolchain and Sphinx configuration to align with Canonical’s Sphinx Stack (1.6) and associated conventions, including changes to redirects, linting (Vale/woke), requirements management, and template/static layout.
Changes:
- Replace dynamic/docs-starter-pack requirements generation with a static
doc/requirements.txt, and migrate config into a singledoc/conf.py. - Adopt Vale-based style/spelling checks and update doc examples to match
sphinx-terminaldirective behavior changes. - Switch redirects from
redirects.py/sphinx-reredirectsstyle toredirects.txt+sphinx-rerediraffe, and move templates/static assets to Sphinx Stack layout.
Reviewed changes
Copilot reviewed 44 out of 50 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| doc/tutorial/single-member.md | Updates {terminal} directive usage (input/output-only formatting). |
| doc/tutorial/multi-member.md | Updates {terminal} directive usage (input/output-only formatting). |
| doc/reuse/substitutions.yaml | Adds centralized substitutions YAML (tracks current LTS/feature). |
| doc/requirements.txt | Introduces static Python requirements for docs tooling/extensions. |
| doc/reference/release-notes/release-notes-template.md | Clarifies template instructions for release note authors. |
| doc/redirects.txt | Adds redirects mapping file for sphinx-rerediraffe. |
| doc/redirects.py | Removes old Python redirects mapping. |
| doc/Makefile.sp | Removes starter-pack Makefile wrapper. |
| doc/Makefile | Replaces build/install/check targets to match Sphinx Stack conventions. |
| doc/how-to/update_upgrade.md | Updates {terminal} directive usage. |
| doc/how-to/snaps.md | Updates {terminal} directive usage. |
| doc/how-to/ovn_underlay.md | Updates {terminal} directive usage. |
| doc/how-to/member_remove.md | Improves terminology clarity (“monmap” → “monitor map”). |
| doc/how-to/ceph_networking.md | Updates {terminal} directive usage and formatting. |
| doc/explanation/security.md | Adds spelling exception markup for “man-in-the-middle”. |
| doc/explanation/initialization.md | Updates {terminal} directive usage; splits combined blocks. |
| doc/doc-cheat-sheet-myst.md | Updates terminal directive guidance and links to sphinx-terminal README. |
| doc/custom_conf.py | Removes legacy split config file (merged into conf.py). |
| doc/conf.py | Consolidates/updates Sphinx configuration for canonical-sphinx + Sphinx Stack. |
| doc/.wordlist.txt | Removes starter-pack wordlist file (moves to Vale approach). |
| doc/.sphinx/version | Records the Sphinx Stack version the docs were aligned to. |
| doc/.sphinx/spellingcheck.yaml | Removes pyspelling configuration (replaced by Vale). |
| doc/.sphinx/get_vale_conf.py | Reworks Vale config download script (clone + copy style guide assets). |
| doc/.sphinx/build_requirements.py | Removes dynamic requirements generator. |
| doc/.sphinx/_templates/sidebar/search.html | Removes legacy sidebar search template override (RTD search removed). |
| doc/.sphinx/_templates/page.html | Removes legacy page template override (moved to new templates layout). |
| doc/.sphinx/_templates/header.html | Removes legacy header template (moved to doc/_templates). |
| doc/.sphinx/_templates/404.html | Removes legacy 404 template (handled differently in new layout). |
| doc/.sphinx/_static/header.css | Removes legacy header styling (replaced by new static layout/CSS). |
| doc/.sphinx/_static/header-nav.js | Removes legacy header dropdown script. |
| doc/.sphinx/_static/github_issue_links.js | Removes legacy “Give feedback” JS injection. |
| doc/.sphinx/_static/github_issue_links.css | Removes legacy styling for feedback link. |
| doc/.sphinx/_static/furo_colors.css | Removes legacy Furo color overrides. |
| doc/.sphinx/_static/footer.js | Removes legacy footer contributors dropdown script. |
| doc/.sphinx/_static/footer.css | Removes legacy footer contributors styling. |
| doc/.sphinx/_static/custom.css | Removes legacy custom CSS bundle from old layout. |
| doc/.sphinx/_static/404.svg | Removes legacy 404 asset from old layout. |
| doc/.sphinx/_integration/rtd-search.js | Removes RTD search integration script. |
| doc/.sphinx/_integration/add_config.py | Updates integrated-build config injection (URLs/paths/tags). |
| doc/.readthedocs.yaml | Updates RTD build commands and requirements path. |
| doc/.gitignore | Updates ignores for new .venv and removed generated files. |
| doc/.custom_wordlist.txt | Adds “subfolders” to custom word list. |
| doc/_templates/header.html | Adds new header template in Sphinx Stack location with accessibility attributes. |
| doc/_templates/google-tag.html | Adds Google Tag Manager include template. |
| doc/_templates/footer.html | Updates footer template and adds license rendering section. |
| doc/_templates/base.html | Adds base template override for JS globals and theme style suppression. |
| doc/_static/microcloud_tag.png | Adds MicroCloud tag image asset. |
| doc/_static/favicon.png | Adds favicon asset. |
| .github/workflows/tests.yml | Sets docs job Python version to 3.12. |
Comments suppressed due to low confidence (2)
doc/_templates/footer.html:47
copyrightindoc/conf.pyalready includes theauthorvalue, but the footer prints{{ copyright }} {{ author }}. This will duplicate the author text in the rendered footer. Either remove{{ author }}here or change thecopyrightstring to exclude the author so it’s only rendered once.
doc/_templates/footer.html:51- Same duplication issue as above in the non-
hasdoc('copyright')branch:{{ copyright }} {{ author }}will repeat the author becausecopyrightalready embeds it.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
roosterfish
left a comment
There was a problem hiding this comment.
Thanks for this, I cannot say much about the doc tooling changes, but I have commented on a few items that caught my eye.
@elijahgreenstein could you please also have a look?
The last commit is causing a failure of the DCO test. I have just earlier merged your PR on link updates, you can now also rebase, maybe this helps.
| with: | ||
| working-directory: './doc' | ||
| makefile: 'Makefile' | ||
| python-version: '3.12' |
There was a problem hiding this comment.
Can we use 3.14? According to https://devguide.python.org/versions/ it seems to be latest stable one.
90f9f10 to
c45675a
Compare
Looks like the issues are resolved and the RTD build is working now. I'll drop that last commit that was failing the DCO check (it was just a test commit to try to refresh the RTD cache). Re: linkchecks, at first it was due to the recent issues, but now I suspect that ubuntu.com has stiffer protections against non-browser requests. |
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Moves code from custom_conf.py into conf.py and aligns it with the Sphinx Stack (formerly the Sphinx Starter Pack). This deliberately excludes the code for the Swagger UI, which will be added into conf.py in a separate commit to make this change easier to backport to the v2-edge branch, which does not use Swagger UI. Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
c45675a to
558c9bb
Compare
Merge Makefile.sp into Makefile and update Makefile to better align with the Sphinx Stack (formerly the Sphinx Starter Pack). Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Replaces use of the canonical-sphinx-extensions extension with the canonical-sphinx extension, adapted for MicroCloud customizations. The canonical-sphinx-extensions package included multiple extensions that have now been split out into their own extensions and updated, including sphinx-terminal, and these have been re-added as needed. Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Set SINGLE_BUILD=True when running linkcheck to avoid issues in CI where only MicroCloud is built and linkcheck looks for the integrated docs. Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Signed-off-by: Minae Lee <minae.lee@canonical.com>
This commit removes the RTD search support, which is already disabled in the RTD project settings due to inconsistent behavior in the MicroCloud docs. Signed-off-by: Minae Lee <minae.lee@canonical.com>
Adds a file to record the last version of sphinx-stack the docs tooling was updated against. Signed-off-by: Minae Lee <minae.lee@canonical.com>
558c9bb to
70ffd52
Compare
Signed-off-by: Minae Lee <minae.lee@canonical.com>
Updates to MicroCloud docs tooling and configuration for improvements as well as to align with standard Canonical docs tooling (Sphinx Stack 1.6, formerly known as Sphinx Starter Pack), including:
:input:option is now handled differently). Update usage of{terminal}directive.linkcheckmake target to prevent GH CI from warning and exiting linkcheck when it tries and fails to find the integration files.sphinx-reredirectsextension withsphinx-rerediraffe, the new default URL redirecter..sphinx/versionfile to record last version of sphinx-stack this docs set was updated against.