Skip to content

Conversation

@MahnoorAsghar
Copy link
Contributor

@MahnoorAsghar MahnoorAsghar commented Aug 8, 2025

Auto-generate API documentation from CRDs

Assisted-by: Claude
Fixes #2509

@metal3-io-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign lentzi90 for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@metal3-io-bot metal3-io-bot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Aug 8, 2025
@tuminoid
Copy link
Member

tuminoid commented Aug 8, 2025

This is copy from IRSO's api doc generator right?

@MahnoorAsghar
Copy link
Contributor Author

@tuminoid

This is copy from IRSO's api doc generator right?

Yes, it is

@MahnoorAsghar MahnoorAsghar force-pushed the crd-doc branch 2 times, most recently from 2a53530 to fbed203 Compare August 8, 2025 15:27
@MahnoorAsghar
Copy link
Contributor Author

/retest-required

@MahnoorAsghar
Copy link
Contributor Author

/retest-required

Copy link
Member

@tuminoid tuminoid left a comment

Choose a reason for hiding this comment

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

The difference between this BMO PR and IRSO here is that IRSO runs the "make manifests" as part of build Github workflow (in a VM), while BMO runs make generate as a Prow job (in a container).

The correct way for BMO would be to have it in a separate Prow job, which runs the crdoc container in Prow.

"${CONTAINER_RUNTIME}" run --rm -v "${PWD}":/src:ro,z \
ghcr.io/fybrik/crdoc:"${CRDOC_VERSION}" \
--resources /src/config/base/crds/bases/ --output /dev/stdout \
> docs/api.md No newline at end of file
Copy link
Member

Choose a reason for hiding this comment

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

missing eol

@MahnoorAsghar MahnoorAsghar changed the title 🌱 Auto-generate API documentation from CRDs WIP 🌱 Auto-generate API documentation from CRDs Sep 25, 2025
@metal3-io-bot metal3-io-bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 25, 2025
@MahnoorAsghar
Copy link
Contributor Author

I dont remember how docs/api-overview.md came from, it must be output from the script, but executing it right now does not create it.

@MahnoorAsghar MahnoorAsghar force-pushed the crd-doc branch 3 times, most recently from 1d6aabf to 861dc18 Compare December 12, 2025 22:42
@MahnoorAsghar
Copy link
Contributor Author

MahnoorAsghar commented Dec 12, 2025

For the check-links-pr job, https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#objectmeta-v1-meta is the correct url, but the crdoc container is generating v1.20 links which are indeed broken

This could be because the latest crdoc container version is 3 years old. There are 2 tagged releases on the repo after that, but no associated container images. See fybrik/crdoc#322

@MahnoorAsghar
Copy link
Contributor Author

@MahnoorAsghar MahnoorAsghar changed the title WIP 🌱 Auto-generate API documentation from CRDs 🌱 Auto-generate API documentation from CRDs Dec 12, 2025
@metal3-io-bot metal3-io-bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Dec 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Generate local API documentation from CRDs

3 participants