--
You received this message because you are subscribed to the Google Groups "Operator Framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to operator-framew...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/operator-framework/cdf86070-c650-4dba-88cf-5f0b0f28683fn%40googlegroups.com.
Product Manager Operator Framework & Quay
Red Hat OpenShift
I will try to share some detailed info, and I hope that helps you.
Pre-requirements
- To run make manifests, you need to have a controller-gen See (here[1]).
- Also, you will need to have kustomize[2]
- And then, to run make test[3], you will need to have the env test binaries[15].
So, you need to ensure that all requirements will be installed before. You can check here[13] how we set up the environment in the CI for SDK and here[14] how we do that in Kubebuilder.
Why do we use Kind?
In Kubebuilder and SDK, we use Kind to test the projects because it allows us to load the manager image that was built in the CI with `kind load docker-image --name`. So, instead of make docker-push you will use that. See here[4] for example. Then, I'd like to recommend you use that. Otherwise, your CI needs to be able to push and pull the image from the public registry.
Use Envtest
Regarding recommendations, I'd like to suggest you test the controllers with Envtest. It is described in the Best Practices section. See here[5] and then, you will see that it has a link for Testing your Operator project[6].
E2e options
Regarding e2e tests, you can do something that is done in Kubebuilder/SDK using Kubebuilder tests utils lib[7] and ginkgo[8]/gomega[9], which makes that significantly easier, allows debugging via an IDE, etc ...
You can check in the SDK, and Kubebuilder repos its examples to test the projects in the testdata. See here[10] and here[11].
Also, you can use the shell script as we did in the past; see an example[12] with the legacy layout for you to have a better idea.
To view this discussion on the web visit https://groups.google.com/d/msgid/operator-framework/CAEQM%2BpNdpWPkTK-jAPPg8EmUwUvA3VqxZdEe60tPsTf5kMF9ZQ%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/operator-framework/04d12c44-7a71-4e4f-8508-af5a1e669ab1n%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/operator-framework/3c559d263a0cfacbccf123cddbeb2906c7cd3104.camel%40redhat.com.