Skip to content

[doc] Add a KubeRay nav section and generalize the section sidebar - #65438

Closed
dstrodtman wants to merge 1 commit into
masterfrom
doc-kuberay-nav-tab
Closed

dstrodtman wants to merge 1 commit into
masterfrom
doc-kuberay-nav-tab

Conversation

@dstrodtman

@dstrodtman dstrodtman commented Aug 12, 2026 •

Copy link
Copy Markdown
Contributor

Why

The KubeRay guides are one of the most-visited parts of the Ray docs, but they're buried two levels down under Ray Clusters and share the global sidebar with the entire site. A reader working through RayService configuration gets every top-level Ray section in the left nav and no KubeRay-specific orientation.

This promotes KubeRay to a top-level nav tab with a sidebar scoped to just KubeRay, reusing the mechanism the APIs tab already ships.

What changed

Navigation (doc/source/navbar.yml)

Use Cases is replaced by a KubeRay tab in the #2 position. Tab order is now Get Started, KubeRay, Example Gallery, Library, APIs, Resources. ray-overview/use-cases still exists and stays in the root toctree and global sidebar; it only loses its tab.

KubeRay also stays in the global sidebar under Ray Clusters, so cluster/getting-started is unchanged and readers browsing Ray Clusters still find it. No page moved, so no URLs change and no redirects are needed.

Section sidebars (doc/source/_ext/api_sidebar.py)

The APIs tab's client-side sidebar mechanism is generalized from one hardcoded section to an N-section table. Adding a section is now a SECTIONS entry (root docname, fragment filename, path prefixes, label, maxdepth) plus a navbar.yml tab — no template or loader change. That also covers the "document the extension's config contract" follow-up from the original APIs work.

Two changes were needed to make it general:

  • Subtree isolation. The old code assumed the section root was a top-level li.toctree-l1 marked current. cluster/kubernetes/index is nested two levels deep, so it isn't. It now walks to the deepest li.current, which is the section root by construction since the toctree was resolved for it. This reduces to the identical result for APIs.
  • Href rebasing. _root_relative stripped exactly one leading ../, hardcoding apis/index's depth-1 position. It now rebases onto dirname(root_docname) via posixpath.normpath, correct at any depth and byte-identical for APIs.

_templates/api-sidebar.html → section-sidebar.html and _static/api-nav-loader.js → section-nav-loader.js; the fragment is per-section (api-nav.html, kuberay-nav.html).

Tab highlighting (doc/source/custom_directives.py)

render_header_nodes compared item["file"] == pagename, so a tab highlighted only on its exact landing page — the APIs tab went dark as soon as you clicked into data/api/…. It now reads context.get("navbar_active_file") or pagename, which the extension sets to the matched section's root. Both the APIs and KubeRay tabs now stay highlighted across their whole section. Tabs outside a section keep the previous exact-match behavior.

No-JS and accessibility fallback

Previously the section sidebar rendered Loading API navigation… and populated entirely from JavaScript, so no-JS readers got no navigation at all. The mount now server-renders the section's top-level pages as a real list of links (from env.toctree_includes, via pathto). The loader upgrades it to the full tree on success and, on failure, leaves it in place rather than replacing it with an error — a failed fetch now degrades to a shallower nav instead of none. aria-busy flips to false on both paths.

This is a meaningful improvement, not full parity: the fallback is the section's top level only, not the whole tree.

Design note: the sidebar swap is intentional

Worth stating up front, because it's the obvious review question. KubeRay keeps its existing position in the global sidebar under Ray Clusters, so nothing moves for readers browsing that section. But once you're on a cluster/kubernetes/** page, the sidebar is replaced by the KubeRay-only tree rather than the KubeRay subtree being highlighted inside the full site nav. Key Concepts, Deploying on VMs, the Applications Guide, and the rest of cluster/ drop out of the left nav until you navigate back out.

That's deliberate. KubeRay is the recommended path for running Ray on Kubernetes and it's a large body of content — around 80 pages across getting-started, user guides, examples, ecosystem integrations, benchmarks, and troubleshooting — currently reachable only by drilling two levels down through Ray Clusters. Surfacing it at the top level and giving it undivided navigation is the point of the change; keeping the whole-site tree alongside it would preserve the discoverability problem this is meant to fix.

Cross-links out of the section (roughly 32 of them, mostly into serve/, ray-observability/, and ray-core/) still work normally and land the reader back on the global sidebar.

Notes for reviewers

  • _ext/api_sidebar.py keeps its name even though the mechanism is no longer APIs-specific. It's referenced by .buildkite/test.rules.txt, .buildkite/test.rules.test.txt, doc/BUILD.bazel, ci/pipeline/BUILD.bazel, and ci/pipeline/test_doc_api_rules_sync.py. Renaming it would pull the shared CI tag-rules surface into this PR. API_PATH_PREFIXES is preserved as a module-level literal tuple so that sync test still parses it out of the AST. There's a docstring note; happy to do the rename as a separate CI-rules PR.
  • Two unrelated black hunks in custom_directives.py. Pre-existing formatting drift in collect_example_orphans. The file isn't in black's exclude list, so pre-commit reformats the whole file on any commit touching it.
  • The fallback nav's titles come from env.titles, i.e. each target page's own title, not any custom label the section root's toctree gives the entry. So the APIs fallback reads "Ray Data API" where the hydrated tree reads "Ray Data". Recovering custom labels needs env.get_doctree(root) per page, too expensive for a fallback. KubeRay uses no custom labels and is unaffected.
  • The no toctree children warning is suppressed when the section root isn't in env.all_docs, so scoped DOC_LIB / build_one_lib builds don't fail under fail_on_warning on an out-of-scope section.

Testing

Opened as a draft because this has not been through a Sphinx build yet — I'm looking to the RtD preview for that. What's verified locally:

  • black clean at the repo's pinned 22.10.0; modules compile; node --check on the loader.
  • ci/pipeline/test_doc_api_rules_sync.py passes (2/2), confirming API_PATH_PREFIXES still parses and stays in sync with the doc_api tag rule.
  • Subtree isolation and href rebasing checked against synthetic toctree HTML for both the depth-1 (APIs) and depth-2 (KubeRay) cases: APIs output unchanged, KubeRay correctly excludes Key Concepts, VMs, and the Ray Clusters parent.
  • section-sidebar.html rendered at three page depths, confirming correct relative fragment URLs, correct relative link targets, and current-page marking.

The main thing the preview needs to confirm is the runtime assumption that global_toctree_for_doc marks current down the nested KubeRay path the way the fixture assumes. Worth a look on the preview:

  • KubeRay tab present at position 2, sidebar scoped to KubeRay on cluster/kubernetes/**.
  • APIs sidebar unchanged from today.
  • Both tabs stay highlighted on section sub-pages.
  • With JavaScript disabled, both sections still show a top-level nav.

Promote the KubeRay guides to a top-level nav tab with a sidebar scoped to
KubeRay, replacing the Use Cases tab. No page moves, so no URLs change and
KubeRay stays reachable under Ray Clusters in the global sidebar.

Generalize the APIs tab's client-side sidebar from one hardcoded section to
an N-section table. Isolating the subtree now walks to the deepest current
list item rather than assuming a top-level one, and hrefs rebase onto the
section root's directory rather than stripping a single "../", so a section
nested at any depth works. Both reduce to the current behavior for APIs.

Keep a navbar tab highlighted across its whole section instead of only on
its landing page, which also fixes the APIs tab going dark on API pages.

Render the section's top-level pages into the sidebar server-side as a
fallback, so the nav works without JavaScript and is present at parse time
for assistive tech. The loader upgrades it to the full tree, and leaves it
in place if the fetch fails rather than replacing it with an error.

Signed-off-by: Douglas Strodtman <[email protected]>
@github-actions

Copy link
Copy Markdown

This pull request has been automatically marked as stale because it has not had
any activity for 14 days. It will be closed in another 14 days if no further activity occurs.
Thank you for your contributions.

You can always ask for help on our discussion forum or Ray's public slack channel.

If you'd like to keep this open, just leave any comment, and the stale label will be removed.

@github-actions github-actions Bot added the stale The issue is stale. It will be closed within 7 days unless there are further conversation label Aug 27, 2026
@github-actions

Copy link
Copy Markdown

This pull request has been automatically closed because there has been no more activity in the 14 days
since being marked stale.

Please feel free to reopen or open a new pull request if you'd still like this to be addressed.

Again, you can always ask for help on our discussion forum or Ray's public slack channel.

Thanks again for your contribution!

@github-actions github-actions Bot closed this Sep 10, 2026
dstrodtman added a commit that referenced this pull request Oct 5, 2026
## Description

KubeRay is one of the most-visited areas of the Ray docs, but it sits
two levels down under Ray Clusters, and every KubeRay URL carries a
redundant `cluster/kubernetes/` prefix. This PR promotes KubeRay to a
top-level entry in the left sidebar and shortens its URLs by moving the
KubeRay docs from `doc/source/cluster/kubernetes/` to
`doc/source/kuberay/`. It replaces the top-nav tab approach from #65438.

All the Ray on Kubernetes docs move to `kuberay/`. KubeRay is the
officially supported way to run Ray on Kubernetes, and the docs already
removed the examples for deploying Ray manually (#53833). The few guides
that apply to Ray on Kubernetes more broadly still use KubeRay for their
examples, so they stay with the rest of the KubeRay docs. The old
`cluster/kubernetes/index` landing page becomes a short
`cluster/kubernetes.md` page under Ray Clusters. It points readers to
KubeRay, says that a manual deployment is possible but not officially
supported, and lists the KubeRay guides that can help with other Ray on
Kubernetes deployments. The KubeRay landing page now covers only
KubeRay.

Previews:

- [Ray on
Kubernetes](https://anyscale-ray--66674.com.readthedocs.build/en/66674/cluster/kubernetes.html)
-
[KubeRay](https://anyscale-ray--66674.com.readthedocs.build/en/66674/kuberay/index.html)

**Please review commit by commit.** Each commit is scoped so it can be
signed off on its own. The PR squash-merges as one change. Commits 3
through 5 came out of an earlier round of review, which kept
KubeRay-independent guides in a general `cluster/kubernetes/` section.
Commits 6 through 8 reverse that: they move those guides back under
KubeRay and turn the general section into a single page. If you're
reviewing for the first time, read commits 3 through 5 with the reversal
in mind. The final state is what commits 1, 2, and 6 through 8 describe.

## Related issues

Related to #65438, which this replaces.

## Additional information

### Commit 1: path change

What to sign off on: every file shows as a git rename, and the only
content deltas are path references that have to move with the files.

- Moves `cluster/kubernetes/` to `kuberay/`, which is 128 files, all
detected as renames. The tree moves as a unit, so the relative `images/`
and `configs/` paths inside it stay valid.
- Renames within the move, since every URL changes anyway:
- Hub pages move into their directories as `index.md`: `benchmarks`,
`examples`, `getting-started`, `references`, `troubleshooting`,
`user-guides`, and `k8s-ecosystem`.
  - `k8s-ecosystem/` becomes `ecosystem/`.
- Drops the redundant `kuberay-` filename prefix from 10 pages:
`getting-started/operator-installation`, and `user-guides/auth`,
`auth-rbac`, `dashboard`, `gcs-ft`, `gcs-persistent-ft`,
`gcs-rocksdb-ft`, `history-server`, `mtls`, `serve-high-throughput`.
- Path references updated with the move:
- Toctrees and `{doc}`/`:doc:`/relative Markdown links inside and
outside the tree (`ray-core/`, `serve/`, `ray-observability/`,
`ray-overview/`, `cluster/`).
  - `.github/CODEOWNERS`: same owners, new path.
  - `.vale.ini`: the path-scoped KubeRay style section.
- `conf.py`: adds `kuberay` to `all_toc_libs`. The directory scan only
picks up `ray-*` names, so without this entry `DOC_LIB=<lib>`
single-library builds would stop excluding KubeRay, and
`DOC_LIB=kuberay` wouldn't work. It previously rode along with
`cluster`.
- `/en/master/` links in the JAX trainer example `README.md` and
`.ipynb`.
- Path mentions in `ray-contribute/writing-style.md`,
`doc/.claude/skills/rst-to-myst/SKILL.md`, and the `_ext/llms_txt.py`
docstring example.
- Left alone on purpose:
- `(kuberay-*)=` and `(k8s-*)=` label definitions and every
label-targeted ref, since labels don't depend on filenames.
- Absolute `docs.ray.io/en/latest/...` and release-pinned links in prose
and in `python/ray/autoscaler/_private/kuberay/autoscaling_config.py`.
The redirects below cover them. Rewriting `/en/latest/` links before a
release ships the new paths would break them.

**Redirects** (`doc/redirects/current.yaml`):

- Specific `page` rules for the 7 hubs, the `k8s-ecosystem/*` prefix,
and the 10 prefix drops, placed before the directory wildcard
`/cluster/kubernetes/*` → `/kuberay/:splat`.
- The existing catch-all `/cluster/kubernetes/*` →
`/cluster/kubernetes/index.html` moves to `from: /kuberay/*` with its
`to:` unchanged, so older releases keep resolving.
- `rtd-redirects validate`: 0 errors, 0 warnings. Chain notes go from 58
to 78.
- `rtd-redirects simulate --prefix /cluster/kubernetes/` passes on
master, latest, `releases-2.58.0`, `releases-2.40.0`, and
`releases-2.20.0`: 0 regressions, 0 wrong landings, 0 new loops on every
version.

Final state, all eight commits, run with `--git-renames doc/source` and
each release's `objects.inv` as its page set:

  | Version | 0 hops | 1 hop | 2 hops | 3 hops |
  |---|---|---|---|---|
  | master (after) | 0 | 271 | 11 | 11 |
  | latest | 97 | 240 | 16 | 0 |
  | releases-2.58.0 | 96 | 240 | 17 | 0 |
  | releases-2.40.0 | 75 | 173 | 40 | 0 |
  | releases-2.20.0 | 66 | 173 | 49 | 0 |

Every page under `/cluster/kubernetes/` on master today reaches its new
path in one hop, including the storage and image pull latency guides and
the landing page itself, `/cluster/kubernetes/index.html`, which lands
on `/kuberay/index.html`. No master URL resolves without a redirect,
because nothing stays under `/cluster/kubernetes/`. The new
`cluster/kubernetes.html` page is a new URL.

The 3-hop entries on master are URLs that don't match any current page,
such as pages removed before this PR. They go from
`/cluster/kubernetes/<page>` to `/kuberay/<page>`, then through the
`/kuberay/*` catch-all to `/cluster/kubernetes/index.html`, then through
the wildcard to `/kuberay/index.html`. They land on the KubeRay landing
page, which is the page they reached before. The catch-all's `to:` stays
`/cluster/kubernetes/index.html` so older releases, which have no
`kuberay/` directory, keep resolving without a loop. The 2-hop entries
on older releases are KubeRay pages newer than that release, and they
land on the same index page as before. The remaining 2-hop entries are
pre-existing chains outside KubeRay, such as RLlib and Tune.

**llms.txt shards.** RtD page redirects fire on any 404 path, not only
`.html`. On today's master,
`/en/master/cluster/kubernetes/no-such-file.txt` already 301s through
the existing `/cluster/kubernetes/*` catch-all. The local build emits
`kuberay/llms-full.txt`, so `/cluster/kubernetes/llms-full.txt` reaches
it through the directory wildcard in one hop, with no extra rule.
`simulate` reports that URL as landing on the index instead, because its
page sources only list HTML pages. It reports the same URL as missing on
today's master, where it returns 200.

### Commit 2: navigation

What to sign off on: sidebar order only.

- Root toctree: adds `KubeRay <kuberay/index>` directly above Ray Core,
and moves `Ecosystem` from above Ray Core to directly below APIs.
- Removes `Deploying on Kubernetes` from the Ray Clusters toctree, so
KubeRay has one parent. Commit 4 restores the entry for the general
section.
- `navbar.yml` doesn't reference KubeRay pages, so it doesn't change.

### Commit 3: keep KubeRay-independent content in `cluster/kubernetes/`

Commit 7 reverses the page moves in this commit. The config file stays
where this commit puts it.

What to sign off on: these files don't depend on the KubeRay operator,
and they keep their master paths.

- Moves back to `cluster/kubernetes/`, as git renames:
  - `user-guides/storage.md`, with its two images.
  - `user-guides/reduce-image-pull-latency.md`.
- `configs/static-ray-cluster.tls.yaml`. It's a plain-Deployment Ray
cluster with no KubeRay, left over from the page #53833 removed, and its
only consumer is `ray-core/configure.md`. Keeping it in place means that
file's raw GitHub link doesn't change at all, so existing copies of the
link keep working.
- `.github/CODEOWNERS`: keeps the `/doc/source/cluster/kubernetes/`
entry alongside the new `/doc/source/kuberay/` one, with the same
owners.
- `.vale.ini`: registers the KubeRay style for both paths.
- The two pages need no redirects, because RtD page redirects only fire
on a 404.

### Commit 4: general Ray on Kubernetes section

Commit 7 replaces this section with a single page,
`cluster/kubernetes.md`.

What to sign off on: navigation only, plus a minimal index page.

- Adds `cluster/kubernetes/index.md` as the parent for the two general
guides. It links to KubeRay for deploying and managing Ray clusters with
the operator. It's intentionally short for now.
- Restores `Deploying on Kubernetes` in the Ray Clusters toctree, now
pointing at that page. KubeRay keeps a single parent, the root toctree.
- Moves the two guides from the KubeRay user-guides toctree to the new
index. The KubeRay user-guides list keeps both as cross-references.
- Updates the Ray on Kubernetes path mention in
`ray-contribute/writing-style.md`.

### Commit 5: landing pages

Commits 6 and 8 revise both pages again.

What to sign off on: prose on the two index pages.

- `kuberay/index.md`: retitles the page from "Ray on Kubernetes" to
"KubeRay" and rewrites the opening as an introduction to KubeRay,
without the "Overview" heading. The `kuberay-index` label moves to the
H1, so its existing refs keep resolving. The custom resource list adds
RayCronJob, so it names all four `ray.io/v1` kinds. The page links to
the general section.
- `cluster/kubernetes/index.md`: lists the operators that deploy and
manage Ray clusters on Kubernetes, which are KubeRay and the Anyscale
operator, with a link to the Anyscale on Kubernetes docs.

### Commit 6: center the KubeRay landing page on KubeRay

What to sign off on: prose on the two landing pages.

- `kuberay/index.md`: removes the Anyscale paragraph. Reframes the card
grid and the "Learn more" lead-in around KubeRay rather than Kubernetes
in general, and sentence-cases the card titles and buttons. Folds the
one-item "About KubeRay" list into prose.
- `cluster/kubernetes/index.md`: cuts the Anyscale operator entry to one
line that links to the Anyscale docs.

### Commit 7: move the general guides back under KubeRay

What to sign off on: path changes only, with no prose edits.

- Moves `storage.md`, its two images, and `reduce-image-pull-latency.md`
back to `kuberay/user-guides/` as git renames, and restores both guides
to the KubeRay user-guides toctree in their original positions.
- Renames `cluster/kubernetes/index.md` to `cluster/kubernetes.md`,
since it no longer has child pages. The Ray Clusters toctree points at
the new path.
- Leaves `cluster/kubernetes/configs/static-ray-cluster.tls.yaml` in
place, so the raw GitHub link in `ray-core/configure.md` doesn't change.
- `.github/CODEOWNERS`: adds `/doc/source/cluster/kubernetes.md` and
keeps the `/doc/source/cluster/kubernetes/` entry for the config file.
`.vale.ini` and `ray-contribute/writing-style.md` point at the new page
path.
- Needs no new redirects. The old master URLs of the two guides reach
their new paths in one hop through the existing `/cluster/kubernetes/*`
wildcard.

### Commit 8: rewrite the Ray on Kubernetes page

What to sign off on: prose on `cluster/kubernetes.md`.

- States that KubeRay is the officially supported way to run Ray on
Kubernetes, and that a manual deployment without an operator is possible
but not officially supported.
- Keeps a one-line pointer to the Anyscale docs for the Anyscale
operator.
- Adds a "KubeRay guides that apply more broadly" section, which links
to the storage and dependencies, image pull latency, managed Kubernetes
cluster setup, and scheduling guides. Their examples use KubeRay, and
the section says so.

### Out of scope

- Expanding `cluster/kubernetes.md` beyond its pointer to KubeRay and
the guide list.
- Reworking the Ray Clusters landing page prose and cards that still
describe Kubernetes as one of two deployment paths.
- `user-guides/k8s-*` slugs (`k8s-autoscaler`, `k8s-cluster-setup`,
`k8s-events`), `persist-kuberay-*-logs`, and
`troubleshooting/troubleshooting.md`. Reviewers: if you'd like any of
these renamed, say so, and it can go in a follow-up so this PR stays a
pure move.

### Verification

- `make -C doc rtd-build` (RtD-faithful, `-W --keep-going`) builds clean
for commits 1 and 2, and for the state after commit 5: `build
succeeded.`, exit 0. The RtD preview build is the check for commits 6
through 8.
- `rtd-redirects validate`: 0 errors, 0 warnings on the final state.
`rtd-redirects simulate` reports 0 regressions, 0 wrong landings, and 0
new loops on every version in the table above.
- Rebased onto master. The only conflict was
`ray-observability/ray-distributed-debugger`, which master converted
from RST to MyST. Commit 1 applies its two quickstart link updates to
the new `.md` file.
- Commit 1 shows all 128 targets as renames in `git show --stat
--find-renames`.

### Coordination

Open PRs touching this directory will need a rebase onto the new paths
after this merges: #65848, #65709, #65965, #66089, #65840. I'll handle
those rebases. Git rename detection should carry most of them over
cleanly.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>
nadongjun pushed a commit to nadongjun/ray that referenced this pull request Oct 6, 2026
## Description

KubeRay is one of the most-visited areas of the Ray docs, but it sits
two levels down under Ray Clusters, and every KubeRay URL carries a
redundant `cluster/kubernetes/` prefix. This PR promotes KubeRay to a
top-level entry in the left sidebar and shortens its URLs by moving the
KubeRay docs from `doc/source/cluster/kubernetes/` to
`doc/source/kuberay/`. It replaces the top-nav tab approach from ray-project#65438.

All the Ray on Kubernetes docs move to `kuberay/`. KubeRay is the
officially supported way to run Ray on Kubernetes, and the docs already
removed the examples for deploying Ray manually (ray-project#53833). The few guides
that apply to Ray on Kubernetes more broadly still use KubeRay for their
examples, so they stay with the rest of the KubeRay docs. The old
`cluster/kubernetes/index` landing page becomes a short
`cluster/kubernetes.md` page under Ray Clusters. It points readers to
KubeRay, says that a manual deployment is possible but not officially
supported, and lists the KubeRay guides that can help with other Ray on
Kubernetes deployments. The KubeRay landing page now covers only
KubeRay.

Previews:

- [Ray on
Kubernetes](https://anyscale-ray--66674.com.readthedocs.build/en/66674/cluster/kubernetes.html)
-
[KubeRay](https://anyscale-ray--66674.com.readthedocs.build/en/66674/kuberay/index.html)

**Please review commit by commit.** Each commit is scoped so it can be
signed off on its own. The PR squash-merges as one change. Commits 3
through 5 came out of an earlier round of review, which kept
KubeRay-independent guides in a general `cluster/kubernetes/` section.
Commits 6 through 8 reverse that: they move those guides back under
KubeRay and turn the general section into a single page. If you're
reviewing for the first time, read commits 3 through 5 with the reversal
in mind. The final state is what commits 1, 2, and 6 through 8 describe.

## Related issues

Related to ray-project#65438, which this replaces.

## Additional information

### Commit 1: path change

What to sign off on: every file shows as a git rename, and the only
content deltas are path references that have to move with the files.

- Moves `cluster/kubernetes/` to `kuberay/`, which is 128 files, all
detected as renames. The tree moves as a unit, so the relative `images/`
and `configs/` paths inside it stay valid.
- Renames within the move, since every URL changes anyway:
- Hub pages move into their directories as `index.md`: `benchmarks`,
`examples`, `getting-started`, `references`, `troubleshooting`,
`user-guides`, and `k8s-ecosystem`.
  - `k8s-ecosystem/` becomes `ecosystem/`.
- Drops the redundant `kuberay-` filename prefix from 10 pages:
`getting-started/operator-installation`, and `user-guides/auth`,
`auth-rbac`, `dashboard`, `gcs-ft`, `gcs-persistent-ft`,
`gcs-rocksdb-ft`, `history-server`, `mtls`, `serve-high-throughput`.
- Path references updated with the move:
- Toctrees and `{doc}`/`:doc:`/relative Markdown links inside and
outside the tree (`ray-core/`, `serve/`, `ray-observability/`,
`ray-overview/`, `cluster/`).
  - `.github/CODEOWNERS`: same owners, new path.
  - `.vale.ini`: the path-scoped KubeRay style section.
- `conf.py`: adds `kuberay` to `all_toc_libs`. The directory scan only
picks up `ray-*` names, so without this entry `DOC_LIB=<lib>`
single-library builds would stop excluding KubeRay, and
`DOC_LIB=kuberay` wouldn't work. It previously rode along with
`cluster`.
- `/en/master/` links in the JAX trainer example `README.md` and
`.ipynb`.
- Path mentions in `ray-contribute/writing-style.md`,
`doc/.claude/skills/rst-to-myst/SKILL.md`, and the `_ext/llms_txt.py`
docstring example.
- Left alone on purpose:
- `(kuberay-*)=` and `(k8s-*)=` label definitions and every
label-targeted ref, since labels don't depend on filenames.
- Absolute `docs.ray.io/en/latest/...` and release-pinned links in prose
and in `python/ray/autoscaler/_private/kuberay/autoscaling_config.py`.
The redirects below cover them. Rewriting `/en/latest/` links before a
release ships the new paths would break them.

**Redirects** (`doc/redirects/current.yaml`):

- Specific `page` rules for the 7 hubs, the `k8s-ecosystem/*` prefix,
and the 10 prefix drops, placed before the directory wildcard
`/cluster/kubernetes/*` → `/kuberay/:splat`.
- The existing catch-all `/cluster/kubernetes/*` →
`/cluster/kubernetes/index.html` moves to `from: /kuberay/*` with its
`to:` unchanged, so older releases keep resolving.
- `rtd-redirects validate`: 0 errors, 0 warnings. Chain notes go from 58
to 78.
- `rtd-redirects simulate --prefix /cluster/kubernetes/` passes on
master, latest, `releases-2.58.0`, `releases-2.40.0`, and
`releases-2.20.0`: 0 regressions, 0 wrong landings, 0 new loops on every
version.

Final state, all eight commits, run with `--git-renames doc/source` and
each release's `objects.inv` as its page set:

  | Version | 0 hops | 1 hop | 2 hops | 3 hops |
  |---|---|---|---|---|
  | master (after) | 0 | 271 | 11 | 11 |
  | latest | 97 | 240 | 16 | 0 |
  | releases-2.58.0 | 96 | 240 | 17 | 0 |
  | releases-2.40.0 | 75 | 173 | 40 | 0 |
  | releases-2.20.0 | 66 | 173 | 49 | 0 |

Every page under `/cluster/kubernetes/` on master today reaches its new
path in one hop, including the storage and image pull latency guides and
the landing page itself, `/cluster/kubernetes/index.html`, which lands
on `/kuberay/index.html`. No master URL resolves without a redirect,
because nothing stays under `/cluster/kubernetes/`. The new
`cluster/kubernetes.html` page is a new URL.

The 3-hop entries on master are URLs that don't match any current page,
such as pages removed before this PR. They go from
`/cluster/kubernetes/<page>` to `/kuberay/<page>`, then through the
`/kuberay/*` catch-all to `/cluster/kubernetes/index.html`, then through
the wildcard to `/kuberay/index.html`. They land on the KubeRay landing
page, which is the page they reached before. The catch-all's `to:` stays
`/cluster/kubernetes/index.html` so older releases, which have no
`kuberay/` directory, keep resolving without a loop. The 2-hop entries
on older releases are KubeRay pages newer than that release, and they
land on the same index page as before. The remaining 2-hop entries are
pre-existing chains outside KubeRay, such as RLlib and Tune.

**llms.txt shards.** RtD page redirects fire on any 404 path, not only
`.html`. On today's master,
`/en/master/cluster/kubernetes/no-such-file.txt` already 301s through
the existing `/cluster/kubernetes/*` catch-all. The local build emits
`kuberay/llms-full.txt`, so `/cluster/kubernetes/llms-full.txt` reaches
it through the directory wildcard in one hop, with no extra rule.
`simulate` reports that URL as landing on the index instead, because its
page sources only list HTML pages. It reports the same URL as missing on
today's master, where it returns 200.

### Commit 2: navigation

What to sign off on: sidebar order only.

- Root toctree: adds `KubeRay <kuberay/index>` directly above Ray Core,
and moves `Ecosystem` from above Ray Core to directly below APIs.
- Removes `Deploying on Kubernetes` from the Ray Clusters toctree, so
KubeRay has one parent. Commit 4 restores the entry for the general
section.
- `navbar.yml` doesn't reference KubeRay pages, so it doesn't change.

### Commit 3: keep KubeRay-independent content in `cluster/kubernetes/`

Commit 7 reverses the page moves in this commit. The config file stays
where this commit puts it.

What to sign off on: these files don't depend on the KubeRay operator,
and they keep their master paths.

- Moves back to `cluster/kubernetes/`, as git renames:
  - `user-guides/storage.md`, with its two images.
  - `user-guides/reduce-image-pull-latency.md`.
- `configs/static-ray-cluster.tls.yaml`. It's a plain-Deployment Ray
cluster with no KubeRay, left over from the page ray-project#53833 removed, and its
only consumer is `ray-core/configure.md`. Keeping it in place means that
file's raw GitHub link doesn't change at all, so existing copies of the
link keep working.
- `.github/CODEOWNERS`: keeps the `/doc/source/cluster/kubernetes/`
entry alongside the new `/doc/source/kuberay/` one, with the same
owners.
- `.vale.ini`: registers the KubeRay style for both paths.
- The two pages need no redirects, because RtD page redirects only fire
on a 404.

### Commit 4: general Ray on Kubernetes section

Commit 7 replaces this section with a single page,
`cluster/kubernetes.md`.

What to sign off on: navigation only, plus a minimal index page.

- Adds `cluster/kubernetes/index.md` as the parent for the two general
guides. It links to KubeRay for deploying and managing Ray clusters with
the operator. It's intentionally short for now.
- Restores `Deploying on Kubernetes` in the Ray Clusters toctree, now
pointing at that page. KubeRay keeps a single parent, the root toctree.
- Moves the two guides from the KubeRay user-guides toctree to the new
index. The KubeRay user-guides list keeps both as cross-references.
- Updates the Ray on Kubernetes path mention in
`ray-contribute/writing-style.md`.

### Commit 5: landing pages

Commits 6 and 8 revise both pages again.

What to sign off on: prose on the two index pages.

- `kuberay/index.md`: retitles the page from "Ray on Kubernetes" to
"KubeRay" and rewrites the opening as an introduction to KubeRay,
without the "Overview" heading. The `kuberay-index` label moves to the
H1, so its existing refs keep resolving. The custom resource list adds
RayCronJob, so it names all four `ray.io/v1` kinds. The page links to
the general section.
- `cluster/kubernetes/index.md`: lists the operators that deploy and
manage Ray clusters on Kubernetes, which are KubeRay and the Anyscale
operator, with a link to the Anyscale on Kubernetes docs.

### Commit 6: center the KubeRay landing page on KubeRay

What to sign off on: prose on the two landing pages.

- `kuberay/index.md`: removes the Anyscale paragraph. Reframes the card
grid and the "Learn more" lead-in around KubeRay rather than Kubernetes
in general, and sentence-cases the card titles and buttons. Folds the
one-item "About KubeRay" list into prose.
- `cluster/kubernetes/index.md`: cuts the Anyscale operator entry to one
line that links to the Anyscale docs.

### Commit 7: move the general guides back under KubeRay

What to sign off on: path changes only, with no prose edits.

- Moves `storage.md`, its two images, and `reduce-image-pull-latency.md`
back to `kuberay/user-guides/` as git renames, and restores both guides
to the KubeRay user-guides toctree in their original positions.
- Renames `cluster/kubernetes/index.md` to `cluster/kubernetes.md`,
since it no longer has child pages. The Ray Clusters toctree points at
the new path.
- Leaves `cluster/kubernetes/configs/static-ray-cluster.tls.yaml` in
place, so the raw GitHub link in `ray-core/configure.md` doesn't change.
- `.github/CODEOWNERS`: adds `/doc/source/cluster/kubernetes.md` and
keeps the `/doc/source/cluster/kubernetes/` entry for the config file.
`.vale.ini` and `ray-contribute/writing-style.md` point at the new page
path.
- Needs no new redirects. The old master URLs of the two guides reach
their new paths in one hop through the existing `/cluster/kubernetes/*`
wildcard.

### Commit 8: rewrite the Ray on Kubernetes page

What to sign off on: prose on `cluster/kubernetes.md`.

- States that KubeRay is the officially supported way to run Ray on
Kubernetes, and that a manual deployment without an operator is possible
but not officially supported.
- Keeps a one-line pointer to the Anyscale docs for the Anyscale
operator.
- Adds a "KubeRay guides that apply more broadly" section, which links
to the storage and dependencies, image pull latency, managed Kubernetes
cluster setup, and scheduling guides. Their examples use KubeRay, and
the section says so.

### Out of scope

- Expanding `cluster/kubernetes.md` beyond its pointer to KubeRay and
the guide list.
- Reworking the Ray Clusters landing page prose and cards that still
describe Kubernetes as one of two deployment paths.
- `user-guides/k8s-*` slugs (`k8s-autoscaler`, `k8s-cluster-setup`,
`k8s-events`), `persist-kuberay-*-logs`, and
`troubleshooting/troubleshooting.md`. Reviewers: if you'd like any of
these renamed, say so, and it can go in a follow-up so this PR stays a
pure move.

### Verification

- `make -C doc rtd-build` (RtD-faithful, `-W --keep-going`) builds clean
for commits 1 and 2, and for the state after commit 5: `build
succeeded.`, exit 0. The RtD preview build is the check for commits 6
through 8.
- `rtd-redirects validate`: 0 errors, 0 warnings on the final state.
`rtd-redirects simulate` reports 0 regressions, 0 wrong landings, and 0
new loops on every version in the table above.
- Rebased onto master. The only conflict was
`ray-observability/ray-distributed-debugger`, which master converted
from RST to MyST. Commit 1 applies its two quickstart link updates to
the new `.md` file.
- Commit 1 shows all 128 targets as renames in `git show --stat
--find-renames`.

### Coordination

Open PRs touching this directory will need a rebase onto the new paths
after this merges: ray-project#65848, ray-project#65709, ray-project#65965, ray-project#66089, ray-project#65840. I'll handle
those rebases. Git rename detection should carry most of them over
cleanly.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stale The issue is stale. It will be closed within 7 days unless there are further conversation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant