Create a strimzi CustomResource in a Golang - operator-sdk based operator #5095
-
when creating a Golang based operator, to use an external custom resources you add
I was wondering how to create a strimzi Cr using my operator, as the operator is not written natively in go, so the API package does not exist in go. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 3 replies
-
We currently support the API in Java of course that helps but not in Go. |
Beta Was this translation helpful? Give feedback.
-
Hi! Just checking if things have changed since last comment 😄 . I have come across a similar usecase and would like to know if client-go |
Beta Was this translation helpful? Give feedback.
-
FYI: I put together a generator for Golang APIs and Kubernetes clients: https://github.com/scholzj/strimzi-go ... if anyone is still interested in this, please check it out and let me know if you have any feedback and/or are interested in using it. |
Beta Was this translation helpful? Give feedback.
We currently support the API in Java of course that helps but not in Go.
I think the only way you have is kind of writing the api package by yourself. I mean, you have to write the corresponding Go structs mapping the Strimzi related custom resource. The simpler way would be having a tool converting the provided CRDs (YAML) into Go structs but I am not aware of such a tool.