Skip to content

Commit 17abca5

Browse files
authored
Fix truncated descriptions in CRD api-docs (#2563)
* Fix truncated descriptions in the documentation Signed-off-by: Israel Blancas <[email protected]> * Add other generated files Signed-off-by: Israel Blancas <[email protected]> * Undo change in version Signed-off-by: Israel Blancas <[email protected]> * Add changelog Signed-off-by: Israel Blancas <[email protected]> * Revert changes in manifest CRDs. Add a way to generate the long descriptions in the MD Signed-off-by: Israel Blancas <[email protected]> * Fix changelog Signed-off-by: Israel Blancas <[email protected]> --------- Signed-off-by: Israel Blancas <[email protected]>
1 parent 9160ce0 commit 17abca5

File tree

3 files changed

+3143
-677
lines changed

3 files changed

+3143
-677
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
2+
change_type: bug_fix
3+
4+
# The name of the component, or a single word describing the area of concern, (e.g. operator, target allocator, github action)
5+
component: documentation
6+
7+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
8+
note: The description for some fields was truncated in the documentation.
9+
10+
# One or more tracking issues related to the change
11+
issues: [2563]
12+
13+
# (Optional) One or more lines of additional information to render under the primary note.
14+
# These lines will be padded with 2 spaces and then inserted directly into the document.
15+
# Use pipe (|) for multiline entries.
16+
subtext:

Makefile

+5-2
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ release-artifacts: set-image-controller
171171
# Generate manifests e.g. CRD, RBAC etc.
172172
.PHONY: manifests
173173
manifests: controller-gen
174-
$(CONTROLLER_GEN) $(CRD_OPTIONS) rbac:roleName=manager-role webhook paths="./..." output:crd:artifacts:config=config/crd/bases
174+
$(CONTROLLER_GEN) $(CRD_OPTIONS) rbac:roleName=manager-role webhook paths="./..." output:crd:artifacts:config=$(MANIFEST_DIR)
175175

176176
# Run tests
177177
# setup-envtest uses KUBEBUILDER_ASSETS which points to a directory with binaries (api-server, etcd and kubectl)
@@ -475,8 +475,11 @@ bundle-push:
475475
api-docs: crdoc kustomize
476476
@{ \
477477
set -e ;\
478+
TMP_MANIFEST_DIR=$$(mktemp -d) ; \
479+
cp -r config/crd/* $$TMP_MANIFEST_DIR; \
480+
$(MAKE) CRD_OPTIONS=$(CRD_OPTIONS),maxDescLen=1200 MANIFEST_DIR=$$TMP_MANIFEST_DIR/bases manifests ;\
478481
TMP_DIR=$$(mktemp -d) ; \
479-
$(KUSTOMIZE) build config/crd -o $$TMP_DIR/crd-output.yaml ;\
482+
$(KUSTOMIZE) build $$TMP_MANIFEST_DIR -o $$TMP_DIR/crd-output.yaml ;\
480483
$(CRDOC) --resources $$TMP_DIR/crd-output.yaml --output docs/api.md ;\
481484
}
482485

0 commit comments

Comments
 (0)