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

docs: Fix gRPC API generation for online docs #27014

Merged
merged 1 commit into from Jul 26, 2023

Conversation

qmonnet
Copy link
Member

@qmonnet qmonnet commented Jul 24, 2023

This is an attempt to fix the gRPC API, which is missing from the hosted version of the documentation. Let's try to symlink the api directory instead of having an additional step to copy it.

I'll mark this PR for backports if it gets merged and if it indeed fixes the API reference on the hosted documentation.

@qmonnet qmonnet added area/documentation Impacts the documentation, including textual changes, sphinx, or other doc generation code. release-note/misc This PR makes changes that have no direct user impact. labels Jul 24, 2023
@qmonnet qmonnet requested review from a team as code owners July 24, 2023 10:27
@qmonnet qmonnet force-pushed the pr/docs-grpc-api-symlink branch 2 times, most recently from bfd7c61 to 5d4a581 Compare July 24, 2023 10:31
@qmonnet
Copy link
Member Author

qmonnet commented Jul 24, 2023

Netlify preview still works 🎉

@qmonnet
Copy link
Member Author

qmonnet commented Jul 24, 2023

... But this will of course require an update of the docs-builder image, that we still haven't automated (#24121)

Edit: No it doesn't, because we pick the Makefile from the repo, not from the image. The CI error was because I missed that we explicitly run make -C Documentation copy-api in the GitHub workflow. I removed it.

@qmonnet qmonnet added the dont-merge/preview-only Only for preview or testing, don't merge it. label Jul 24, 2023
@qmonnet qmonnet requested a review from a team as a code owner July 24, 2023 10:44
To generate the gRPC API reference, we copy the "api" repository at the
root of the repository to "Documentation/_api". This step is required
everywhere we need to build the docs:

  - Locally, we run it through the "copy-api" target in
    Documentation/Makefile, before generating the HTML.
  - Same thing for the Netlify preview, where "copy-api" is a dependency
    for the "html-netlify" target.
  - However, on ReadTheDocs, where we generate and host the online
    documentation, we do not perform this step; nor do we use the
    Makefile at all.

As a workaround, let's simplify the way we access the API reference.
Instead of copying the docs, just symlink them from the Documentation
directory.

Signed-off-by: Quentin Monnet <quentin@isovalent.com>
@qmonnet qmonnet removed the dont-merge/preview-only Only for preview or testing, don't merge it. label Jul 24, 2023
Copy link
Contributor

@viktor-kurchenko viktor-kurchenko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Copy link
Contributor

@zacharysarah zacharysarah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a reasonable approach to me.

@qmonnet qmonnet added the ready-to-merge This PR has passed all tests and received consensus from code owners to merge. label Jul 25, 2023
@youngnick youngnick merged commit 944dddf into cilium:main Jul 26, 2023
55 checks passed
@qmonnet qmonnet deleted the pr/docs-grpc-api-symlink branch July 26, 2023 08:12
@qmonnet
Copy link
Member Author

qmonnet commented Jul 26, 2023

I confirm the issue is fixed on the online doc 🎉

Let's mark this for backports.

@qmonnet qmonnet added needs-backport/1.12 needs-backport/1.13 This PR / issue needs backporting to the v1.13 branch needs-backport/1.14 This PR / issue needs backporting to the v1.14 branch labels Jul 26, 2023
@maintainer-s-little-helper maintainer-s-little-helper bot added this to Needs backport from main in 1.12.12 Jul 26, 2023
@maintainer-s-little-helper maintainer-s-little-helper bot added this to Needs backport from main in 1.13.5 Jul 26, 2023
@gentoo-root gentoo-root added this to Needs backport from main in 1.12.13 Jul 26, 2023
@gentoo-root gentoo-root removed this from Needs backport from main in 1.12.12 Jul 26, 2023
@gentoo-root gentoo-root added this to Needs backport from main in 1.13.6 Jul 26, 2023
@gentoo-root gentoo-root removed this from Needs backport from main in 1.13.5 Jul 26, 2023
@nbusseneau nbusseneau mentioned this pull request Jul 26, 2023
2 tasks
@nbusseneau nbusseneau mentioned this pull request Jul 26, 2023
2 tasks
@nbusseneau nbusseneau added backport-pending/1.13 The backport for Cilium 1.13.x for this PR is in progress. and removed needs-backport/1.13 This PR / issue needs backporting to the v1.13 branch labels Jul 26, 2023
@nbusseneau nbusseneau mentioned this pull request Jul 26, 2023
6 tasks
@nbusseneau nbusseneau added backport-pending/1.14 The backport for Cilium 1.14.x for this PR is in progress. and removed needs-backport/1.14 This PR / issue needs backporting to the v1.14 branch labels Jul 26, 2023
@joestringer joestringer added backport-done/1.14 The backport for Cilium 1.14.x for this PR is done. and removed backport-pending/1.14 The backport for Cilium 1.14.x for this PR is in progress. labels Jul 26, 2023
@nbusseneau nbusseneau added backport-done/1.12 The backport for Cilium 1.12.x for this PR is done. backport-done/1.13 The backport for Cilium 1.13.x for this PR is done. and removed backport-pending/1.12 backport-pending/1.13 The backport for Cilium 1.13.x for this PR is in progress. labels Jul 31, 2023
@nebril nebril moved this from Needs backport from main to Backport done to v1.13 in 1.13.6 Aug 10, 2023
@asauber asauber moved this from Needs backport from main to Backport done to v1.12 in 1.12.13 Aug 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/documentation Impacts the documentation, including textual changes, sphinx, or other doc generation code. backport-done/1.12 The backport for Cilium 1.12.x for this PR is done. backport-done/1.13 The backport for Cilium 1.13.x for this PR is done. backport-done/1.14 The backport for Cilium 1.14.x for this PR is done. ready-to-merge This PR has passed all tests and received consensus from code owners to merge. release-note/misc This PR makes changes that have no direct user impact.
Projects
No open projects
1.12.13
Backport done to v1.12
1.13.6
Backport done to v1.13
Development

Successfully merging this pull request may close these issues.

None yet

7 participants