# Clientset for Client-go

**URL:** <https://discuss.elastic.co/t/clientset-for-client-go/231795>\
**Category:** Elastic Cloud on Kubernetes (ECK)\
**Created:** [May 8, 2020, 8:27pm UTC](https://discuss.elastic.co/t/clientset-for-client-go/231795 "2020-05-08T20:27:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ReeSilva](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/reesilva/32/12129_2.png) [@ReeSilva](https://discuss.elastic.co/u/ReeSilva)\
**Post date:** [May 8, 2020, 8:27pm UTC](https://discuss.elastic.co/t/clientset-for-client-go/231795/1 "2020-05-08T20:27:51Z")

</div>

Hey guys, I'm trying to write a Terraform Provider to handle ECK resources (@ begin, ES and Kibana). Does the operator implements clientset to create a client using Kubernetes client-go? Or I have to create it myself using the types created on `pkg/apis/elasticsearch/v1/elasticsearch_types.go`?

If it doesn't implement it, does anyone did that?

Thank u in advance.

---

<div class="post-metadata">

**Author:** ![charith-elastic](https://avatars.discourse-cdn.com/v4/letter/c/3ec8ea/32.png) [@charith-elastic](https://discuss.elastic.co/u/charith-elastic)\
**Post date:** [May 11, 2020, 9:37am UTC](https://discuss.elastic.co/t/clientset-for-client-go/231795/2 "2020-05-11T09:37:35Z")

</div>

There is no ClientSet implementation. I think your options are:

- Use the `Unstructured` client (doesn't require a dependency on ECK)
- Use `github.com/elastic/cloud-on-k8s/pkg/controller/common/scheme.SetupScheme()` method to register ECK types with the client-go scheme. You can then use client-go to access ECK objects.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [November 4, 2022, 7:57am UTC](https://discuss.elastic.co/t/clientset-for-client-go/231795/3 "2022-11-04T07:57:28Z")

</div>


