I have a custom-resource.yml to deploy k6 tests on kubernetes. I have followed the documentation here to Running distributed k6 tests on Kubernetes
to successfully run these tests in K8s before. But, recently i have started hitting the below error
kubectl apply -f /path/custom-resource.yml
error: unable to recognize "/path/custom-resource.yml": no matches for kind "K6" in version k6ioalpha1
Below is how my custom-resource.yaml looks like
apiVersion: k6.io/v1alpha1
kind: K6
metadata:
name: k6-mbi-load
namespace: k6-mbi-test
labels:
app: k6-load-test-app
spec:
parallelism: 4
Any help is appreciated.
Thanks,
Madhan
Hi @madk6load,
Welcome to the forum 
It looks like CRD definition wasn’t deployed in your cluster. Or since you had successful tests before, maybe it got destroyed by something?
You can check whether CRD is deployed or not with this command:
kubectl get crd
You should see output similar to this:
NAME CREATED AT
k6s.k6.io 2022-08-19T14:48:27Z
Normally, CRD is deployed with make deploy
so if CRD got ‘lost’, this command should be re-run.
Let me know if that helps!
Hello olha,

Yes, that absolutely helps. It looks like something in the background has destroyed the CRD definition and i was blindsided by this.
I checked K6 CRDs to find out it does not exist anymore in the cluster.
Will investigate root cause and get this fixed. Thanks again for the quick response.
Cheers,
Madhan
1 Like