fix(docs): publish docs.nvidia.com from 26.05 branch#2310
Conversation
Build the MkDocs site from the 26.05 release branch instead of main so the 26.5.0 docs on docs.nvidia.com reflect the release, not in-progress main content. The canonical versions.json (version picker + latest alias) is still sourced from main, since it does not live on 26.05.
Greptile SummaryThis PR changes the docs.nvidia.com publish workflow for the 26.5.0 docs. The main changes are:
|
| Filename | Overview |
|---|---|
| .github/workflows/nrl-docs-nvidia-publish.yml | The workflow now builds docs from 26.05 while sourcing versions.json from main; the changed checkout ref needs stronger immutability or protection before publishing. |
Prompt To Fix All With AI
Fix the following 1 code review issue. Work through them one at a time, proposing concise fixes.
---
### Issue 1 of 1
.github/workflows/nrl-docs-nvidia-publish.yml:153
**Mutable Release Branch Publishes Content**
When this workflow runs from `main`, the docs artifact is now built from the current tip of `26.05` and then published by the later AWS/Akamai-backed job. If `26.05` can change outside the same protected release review path as `main`, a later push, tag, or manual dispatch on `main` can publish unreviewed docs content under the trusted `26.5.0` URL.
Reviews (1): Last reviewed commit: "fix(docs): publish docs.nvidia.com from ..." | Re-trigger Greptile
| - name: Checkout 26.05 docs content | ||
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | ||
| with: | ||
| ref: "26.05" |
There was a problem hiding this comment.
Mutable Release Branch Publishes Content
When this workflow runs from main, the docs artifact is now built from the current tip of 26.05 and then published by the later AWS/Akamai-backed job. If 26.05 can change outside the same protected release review path as main, a later push, tag, or manual dispatch on main can publish unreviewed docs content under the trusted 26.5.0 URL.
Prompt To Fix With AI
This is a comment left during a code review.
Path: .github/workflows/nrl-docs-nvidia-publish.yml
Line: 153
Comment:
**Mutable Release Branch Publishes Content**
When this workflow runs from `main`, the docs artifact is now built from the current tip of `26.05` and then published by the later AWS/Akamai-backed job. If `26.05` can change outside the same protected release review path as `main`, a later push, tag, or manual dispatch on `main` can publish unreviewed docs content under the trusted `26.5.0` URL.
How can I resolve this? If you propose a fix, please make it concise.
Summary
docs/mkdocs.yml,docs/requirements.txt,docs/docs/**) instead ofmain.versions.json(version picker +latestalias) sourced frommain, since it does not exist on26.05.26.5.0; only the source of the published pages changes.Why
The publish workflow lives on
mainand previously checked out the triggering ref (main), sodocs.nvidia.com/nemo/retriever/26.5.0/was being built frommain. Asmainmoves toward the next release, its docs must not be published under the26.5.0label. Pinning the content checkout to26.05fixes this while keeping the secret-bearing publish job onmain(no new exposure, no26.05branch-protection dependency).Triggering
Runs on push to
main(docs paths), release tags, or manualworkflow_dispatch— all build26.05content. (Auto-publish on26.05pushes is intentionally not added, to avoid exposing AWS/Akamai secrets to unprotected-branch pushes.)Test plan
docs/mkdocs.ymlanddocs/requirements.txtexist on26.05.workflow_dispatchwithdry-run: trueto confirm the 26.05 build succeeds before a live publish.