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

Add support for generating CRD's for entities that contain other custom resources #823

Merged
merged 2 commits into from
Dec 16, 2024

Conversation

gamingrobot
Copy link
Contributor

This adds support for a CustomKubernetesEntity that has another CustomKubernetesEntity as a property. We use this for cluster resources that create namespaced versions, so we want the spec to match without having to duplicate the spec inside the parent CustomKubernetesEntity. https://github.com/Contrast-Security-OSS/agent-operator/blob/master/src/Contrast.K8s.AgentOperator/Entities/V1Beta1ClusterAgentConnection.cs

In previous versions of the sdk the generator supported this scenario but the current one errors out with System.ArgumentException: The given type Contrast.K8s.AgentOperator.Entities.V1Beta1AgentConfiguration is not a valid Kubernetes entity. inside the Map function.

Also cleaned up the xml doc on the description attribute since the new generator doesn't support pulling the description from the xml summary.

@buehler
Copy link
Owner

buehler commented Dec 16, 2024

Hey @gamingrobot

Thank you for your contribution!
I'm sorry for the very late answer, I'm currently doing studies which take a lot of time ;-)

@buehler buehler merged commit f2129cf into buehler:main Dec 16, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants