Terraform - Is it possible to start an elasticsearch cluster locally on docker-desktop/k8s with terraform?

I would like to use kubernetes provider on terraform to start an elasticsearch clusters.

Is that feasible?
What's the proper way to do it?

Thank you