Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a workflow to enforce new docs redirects #289

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ptgott
Copy link
Contributor

@ptgott ptgott commented Nov 7, 2024

Add a docpaths workflow to the bot to ensure that any renamed or deleted docs pages accompany a new redirect in the docs config file (config.json). This way, we can prevent docs changes from introducing 404s, whether because of delays in search engine indexing or broken links from Teleport-owned sites.

The workflow takes a path to a config.json file, loads the redirect configuration, and checks whether all renamed and deleted pages correspond to a redirect. This change adds a docpaths value of the workflow flag and an optional teleport-path flag for the path to a gravitational/teleport clone so the workflow can locate a docs configuration file.

@ptgott ptgott requested a review from a team as a code owner November 7, 2024 15:48
@ptgott
Copy link
Contributor Author

ptgott commented Nov 7, 2024

Here is an example of a failing workflow run in a v16 test PR: https://github.com/gravitational/teleport/actions/runs/11746390534/job/32726045359?pr=48546#step:7:18

@ptgott ptgott marked this pull request as draft November 8, 2024 17:00
@ptgott ptgott force-pushed the paul.gottschling/2024-11-06-docs-redirs branch from 07dbd57 to 4b50bc2 Compare November 8, 2024 17:03
@ptgott ptgott marked this pull request as ready for review November 8, 2024 17:08
@ptgott ptgott force-pushed the paul.gottschling/2024-11-06-docs-redirs branch 2 times, most recently from 0c1621e to d9e5a50 Compare November 8, 2024 17:14
@ptgott ptgott force-pushed the paul.gottschling/2024-11-06-docs-redirs branch from d9e5a50 to de56c4f Compare November 19, 2024 21:09
Add a `docpaths` workflow to the bot to ensure that any renamed or
deleted docs pages accompany a new redirect in the docs config file
(`config.json`). This way, we can prevent docs changes from introducing
404s, whether because of delays in search engine indexing or broken
links from Teleport-owned sites.

The workflow takes a path to a `config.json` file, loads the redirect
configuration, and checks whether all renamed and deleted pages
correspond to a redirect. This change adds a `docpaths` value of the
`workflow` flag and an optional `teleport-path` flag for the path to
a `gravitational/teleport` clone so the workflow can locate a docs
configuration file.
@ptgott ptgott force-pushed the paul.gottschling/2024-11-06-docs-redirs branch from de56c4f to 5b46fbd Compare December 24, 2024 15:03
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