Skip to content

PullPolicy link fix - #1007

Closed
kristin-kronstain-brown wants to merge 1 commit into
mainfrom
kkb-links-9-1-26
Closed

PullPolicy link fix#1007
kristin-kronstain-brown wants to merge 1 commit into
mainfrom
kkb-links-9-1-26

Conversation

@kristin-kronstain-brown

@kristin-kronstain-brown kristin-kronstain-brown commented Sep 1, 2026

Copy link
Copy Markdown
Collaborator

Fixes a broken anchor in the generated API reference.

crd-ref-docs templates a kubernetes.io URL for every k8s type, so the pullPolicy field links to #pullpolicy-v1-core. That anchor doesn't exist — PullPolicy is a type alias with no section of its own — so the link drops readers at the top of a very long API page. Repointed to the concepts page, which is where the field is actually documented.

The rewrite is one sed added to the post-processing block that already runs in Generate agentgateway API docs, plus a guard that fails the run if the pattern stops matching, so a silently-stale regex can't quietly reintroduce the bad anchor.

Why here and not elsewhere

  • Not in knownTypes. LinkForType checks IsKubeType before IsKnownType, so any entry for a k8s type is silently ignored. An entry for PullPolicy used to live in the config and never took effect.
  • Not by editing api-*.md. The reference docs regenerate nightly, so a hand-edit is reverted within a day.
  • Not a lychee exclusion. The anchor is genuinely dead, not a checker artifact. Excluding it would hide a real defect rather than remove noise.

Upstream

elastic/crd-ref-docs#143 flips that ordering so knownTypes wins, which would make this workaround unnecessary. It's been open since March 2025 and needs a rebase. If it merges, we pick it up automatically (the workflow runs @latest) and can drop the sed in favor of a knownTypes entry.

Signed-off-by: Kristin Brown <kristin.brown@solo.io>
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying agentproxy with  Cloudflare Pages  Cloudflare Pages

Latest commit: e14f41d
Status: ✅  Deploy successful!
Preview URL: https://ce846581.agentproxy.pages.dev
Branch Preview URL: https://kkb-links-9-1-26.agentproxy.pages.dev

View logs

@kristin-kronstain-brown

Copy link
Copy Markdown
Collaborator Author

Moved into: #1004

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant