-
Notifications
You must be signed in to change notification settings - Fork 3
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
Merged
Merged
Conversation
This file contains 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
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 |
07dbd57
to
4b50bc2
Compare
0c1621e
to
d9e5a50
Compare
d9e5a50
to
de56c4f
Compare
de56c4f
to
5b46fbd
Compare
5b46fbd
to
b96e8e0
Compare
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.
b96e8e0
to
aae6322
Compare
zmb3
reviewed
Jan 31, 2025
- Remove an unnecessary type declaration. - Rename `Redirect` to `DocsRedirect` for clarity. - Fix code comment. - Fix `trace.Wrap` usage. - Use filepath instead of path. - Make toURLPath clearer.
zmb3
approved these changes
Feb 4, 2025
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.
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 adocpaths
value of theworkflow
flag and an optionalteleport-path
flag for the path to agravitational/teleport
clone so the workflow can locate a docs configuration file.