Repository navigation
Conversation
Pages removed or renamed here kept returning 404 on smallstep.com because nothing required a redirect. Old URLs now go in redirects.json, and a pull request check fails when a served page disappears without an entry there, or when an entry points at a docs page that doesn't exist. redirects.json starts with the URLs that are currently returning 404, including the four guides folded into protect-wireless-networks and the removed mutual-tls-aws tutorial. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Docs pages that were removed or renamed kept returning 404 on smallstep.com. The page list lives here and the redirects lived in the site repo, and nothing connected the two. The four guides folded into
protect-wireless-networksand the removedmutual-tls-awstutorial are recent examples.What changes
redirects.json: the list of old docs URLs and where they go now. It starts with 19 entries for URLs that are returning 404 today.removed-pagescheck: runs on every pull request. It compares the pages served before and after the change and fails when:redirects.jsonentry/docspage that isn't servedfromis still a live page, is duplicated, or isn't written as a plain/docs/...pathCONTRIBUTING.md: a "Removing or renaming a page" section.trigger-algolia-index.yml: a change toredirects.jsonnow notifies the site, so a redirect-only change takes effect without waiting for the cache to expire.The check is a Node script with no dependencies and needs no secrets, so it runs on pull requests from forks.
Merge order
The site reads
redirects.jsonstarting with smallstep/smallstep.com#1283. Until that is deployed, the entries here do nothing, so this should merge after it.Testing
node --test .github/scripts/check-removed-pages.test.mjs).main(343 pages served).valeand the Markdown link check were not run locally; both pass in CI on this pull request.🤖 Generated with Claude Code