-
Notifications
You must be signed in to change notification settings - Fork 1
Move crds to templates folder #19
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
Conversation
- Update makefile to add a conditional block to the qdrantversions template - Add parameter to the chart values - Remove duplicated qdrantversions.yaml file
737bdad
to
00e4bd6
Compare
rm charts/qdrant-operator-crds/templates/management-crds/*.yaml | ||
rm charts/qdrant-operator-crds/templates/region-crds/*.yaml | ||
$(CONTROLLER_GEN) crd paths="./..." output:crd:artifacts:config=charts/qdrant-operator-crds/templates | ||
mv charts/qdrant-operator-crds/templates/qdrant.io_qdrantversions.yaml charts/qdrant-operator-crds/templates/management-crds/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe not for this PR, but we want to rename QdrantVersion to QdrantRelease
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yup, there is ticket for that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -20,8 +20,20 @@ gen: manifests generate format vet ## Generate code containing DeepCopy, DeepCop | |||
|
|||
.PHONY: manifests | |||
manifests: controller-gen ## Generate CustomResourceDefinition objects. | |||
$(CONTROLLER_GEN) crd paths="./..." output:crd:artifacts:config=charts/qdrant-operator-crds/crds | |||
cp charts/qdrant-operator-crds/crds/qdrant.io_qdrantversions.yaml charts/qdrant-operator-crds/crds-for-cluster-api/qdrant.io_qdrantversions.yaml | |||
rm charts/qdrant-operator-crds/templates/management-crds/*.yaml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we need to keep them in git repo at all, if everybody just consumes the published chart?
@@ -20,8 +20,20 @@ gen: manifests generate format vet ## Generate code containing DeepCopy, DeepCop | |||
|
|||
.PHONY: manifests | |||
manifests: controller-gen ## Generate CustomResourceDefinition objects. | |||
$(CONTROLLER_GEN) crd paths="./..." output:crd:artifacts:config=charts/qdrant-operator-crds/crds |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these two lines got expanded into 13 lines. I would suggest to move this logic into a script under hack
directory, keeping the makefile easier to read and making the script testable.
Currently, the CRDs are created during
helm install
but they aren't updated.This PR moves them from
crds
totemplates
to solve that.It also introduces a new parameter to control if the
qdrantversions
CRD has to be installed.