Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error no matches for kind ScaledObject in version keda.sh/v1alpha1 #100

Closed
Fel3180 opened this issue Nov 11, 2020 · 25 comments
Closed

Error no matches for kind ScaledObject in version keda.sh/v1alpha1 #100

Fel3180 opened this issue Nov 11, 2020 · 25 comments

Comments

@Fel3180
Copy link

Fel3180 commented Nov 11, 2020

I am trying to install KEDA through ArgoCD. Am getting the below error.

ERROR   controller-runtime.source       if kind is a CRD, it should be installed before calling
Start   {"kind": "ScaledJob.keda.sh", "error": "no matches for kind \"ScaledJob\" in version \"keda.sh/v1alpha1\""}
github.com/go-logr/zapr.(*zapLogger).Error
        /go/pkg/mod/github.com/go-logr/zapr@v0.1.1/zapr.go:128
sigs.k8s.io/controller-runtime/pkg/source.(*Kind).Start
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.6.2/pkg/source/source.go:117
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func1
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.6.2/pkg/internal/controller/controller.go:140
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.6.2/pkg/internal/controller/controller.go:175
sigs.k8s.io/controller-runtime/pkg/manager.(*controllerManager).startRunnable.func1
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.6.2/pkg/manager/internal.go:661
2020-11-11T12:56:52.245Z        ERROR   controller-runtime.source       if kind is a CRD, it should be installed before calling
Start   {"kind": "ScaledObject.keda.sh", "error": "no matches for kind \"ScaledObject\" in version \"keda.sh/v1alpha1\""}
github.com/go-logr/zapr.(*zapLogger).Error
        /go/pkg/mod/github.com/go-logr/zapr@v0.1.1/zapr.go:128
sigs.k8s.io/controller-runtime/pkg/source.(*Kind).Start
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.6.2/pkg/source/source.go:117
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func1
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.6.2/pkg/internal/controller/controller.go:140
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.6.2/pkg/internal/controller/controller.go:175
sigs.k8s.io/controller-runtime/pkg/manager.(*controllerManager).startRunnable.func1
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.6.2/pkg/manager/internal.go:661
2020-11-11T12:56:52.245Z        ERROR   setup   problem running manager {"error": "no matches for kind \"ScaledJob\" in version
\"keda.sh/v1alpha1\""}
github.com/go-logr/zapr.(*zapLogger).Error
        /go/pkg/mod/github.com/go-logr/zapr@v0.1.1/zapr.go:128
main.main
        /workspace/main.go:119
runtime.main
        /usr/local/go/src/runtime/proc.go:204

Specifications

KEDA Version: 2.0
Kubernetes Version: 1.18

Screenshot from 2020-11-11 09-47-47

@tomkerkhove
Copy link
Member

Thanks for the report - How did you install KEDA?

@zroubalik
Copy link
Member

zroubalik commented Nov 12, 2020

Seems like your CRDs are not installed.

What kubectl get crd | grep keda gives you?

@Fel3180
Copy link
Author

Fel3180 commented Nov 12, 2020

I did the installation via Charts at the startup of the Cluster by ArgoCD. I made a clone of this project https://github.com/kedacore/charts and added it to the Argo structure to do the installation.

This kubectl get crd command | grep keda returns nothing.

@zroubalik
Copy link
Member

So your CRDs are not installed. You need to install them in the cluster in order to use KEDA.

@Fel3180
Copy link
Author

Fel3180 commented Nov 12, 2020

So as I am using ArgoCD this installation would be done through Charts, in the repository that I cloned has the following .yaml for installing the CRDS:
scaledjobs.keda.sh.yaml
scaledobjects.keda.sh.yaml
triggerauthentications.keda.sh.yaml

@zroubalik
Copy link
Member

zroubalik commented Nov 12, 2020

yes, those needed to be installed in the cluster. Not sure how does the ArgoCD installation work, but it is probably missing this part.

@Fel3180
Copy link
Author

Fel3180 commented Nov 12, 2020

So this is exactly what I'm trying to do to install Keda. This error is mentioned in the installation.

@zroubalik
Copy link
Member

We don't support installation via ArgoCD, it is not something that has been tested, so my guess that something is not correct there. Could you try to install KEDA directly via one of our supported methods? This should work and install the CRD correctly.

@allenmun197
Copy link
Contributor

allenmun197 commented Nov 16, 2020

So argocd is installing via helm2 as apiVersion in Chart.yaml is set to v1 instead of using the recommended helm3.
This is a PR to fix this issue
#101

@Fel3180
Copy link
Author

Fel3180 commented Nov 18, 2020

Thanks @allenmunC1. I will try with this PR.

@Fel3180
Copy link
Author

Fel3180 commented Nov 19, 2020

@allenmunC1 I used this fix, but I found a new problem. The keda-operator is reporting the following error:

E1119 20:10:04.006257 1 reflector.go:178] pkg/mod/k8s.io/client-go@v0.18.8/tools/cache/reflector.go:125: Failed to list v
1alpha1.ScaledObject: the server could not find the requested resource (get scaledobjects.keda.sh)***

@tomkerkhove
Copy link
Member

@Fel3180 I've noticed you had issues installing through Helm 2 in another issue, is this the same case here? Because that might be the root cause of your problem?

@Fel3180
Copy link
Author

Fel3180 commented Nov 20, 2020

Exactly @tomkerkhove, I'm having trouble installing with Helm 2. Would you have any solution for this? Knowing that I can't update the helm in my cluster.

@tomkerkhove
Copy link
Member

Unfortunately you'll have to stick with KEDA 1.5 fo now then.

We have removed support for Helm 2 in KEDA 2.0

@zroubalik
Copy link
Member

@Fel3180 you can always install KEDA via yaml file: https://keda.sh/docs/2.0/deploy/#yaml

@Fel3180
Copy link
Author

Fel3180 commented Nov 20, 2020

Ok @zroubalik, I will try this option.

@tomkerkhove
Copy link
Member

Did it work out?

@Fel3180
Copy link
Author

Fel3180 commented Nov 30, 2020

Hi, @tomkerkhove, did not work, I'm trying install a version 1.5.

@tomkerkhove
Copy link
Member

Same issue as in #100 (comment)?

@Fel3180 Fel3180 closed this as completed Nov 30, 2020
@Fel3180 Fel3180 reopened this Nov 30, 2020
@Fel3180
Copy link
Author

Fel3180 commented Nov 30, 2020

Yes, that it's, because I'm using Helm2.

@Fel3180
Copy link
Author

Fel3180 commented Dec 7, 2020

@tomkerkhove I'm having this problem installing KEDA.

W
I1204 14:37:10.712351       1 shared_informer.go:230] Caches are synced for client-ca::kube-system::extension-apiserver-authenti
cation::client-ca-file
E1204 22:20:14.519191       1 provider.go:134] keda_metrics_adapter/provider "msg"="Cannot get list of ScaledObjects" "error"="e
tcdserver: request timed out"  "WatchedNamespace"=""
E1206 14:07:56.025680       1 webhook.go:199] Failed to make webhook authorizer request: Post "https://10.0.0.1:443/apis/authori
zation.k8s.io/v1/subjectaccessreviews": context canceled
E1206 14:07:56.025857       1 errors.go:77] Post "https://10.0.0.1:443/apis/authorization.k8s.io/v1/subjectaccessreviews": conte
xt canceled
E1206 14:07:58.535347       1 webhook.go:199] Failed to make webhook authorizer request: Post "https://10.0.0.1:443/apis/authori
zation.k8s.io/v1/subjectaccessreviews": context canceled
E1206 14:07:58.535493       1 errors.go:77] Post "https://10.0.0.1:443/apis/authorization.k8s.io/v1/subjectaccessreviews": conte
xt canceled
E1206 14:08:35.552129       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.552398       1 errors.go:77] context canceled
E1206 14:08:35.553001       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.553218       1 errors.go:77] context canceled
E1206 14:08:35.553460       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.552139       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.553784       1 errors.go:77] context canceled
E1206 14:08:35.552139       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.553978       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.554097       1 errors.go:77] context canceled
E1206 14:08:35.554115       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.554229       1 errors.go:77] context canceled
E1206 14:08:35.554109       1 errors.go:77] context canceled
E1206 14:08:35.553865       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.554345       1 errors.go:77] context canceled
E1206 14:08:35.554800       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.554902       1 errors.go:77] context canceled
E1206 14:08:35.556128       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.556283       1 errors.go:77] context canceled
E1206 14:08:35.556296       1 errors.go:77] context canceled
E1206 14:08:35.558244       1 webhook.go:199] Failed to make webhook authorizer request: context canceled
E1206 14:08:35.558501       1 errors.go:77] context canceled
E1207 11:33:03.827405       1 provider.go:134] keda_metrics_adapter/provider "msg"="Cannot get list of ScaledObjects" "error"="e
tcdserver: request timed out"  "WatchedNamespace"=""

Screenshot from 2020-12-07 08-42-33

@tomkerkhove
Copy link
Member

@zroubalik have you seen this before?

@Fel3180
Copy link
Author

Fel3180 commented Dec 8, 2020

Thanks @tomkerkhove , my team solved this problem, it was a bug in Argo, I will close the issue, thanks.

@Fel3180 Fel3180 closed this as completed Dec 8, 2020
@muqtadir
Copy link

muqtadir commented Mar 7, 2021

@Fel3180 can you please describe how to solve the problem.

@OpakAlex
Copy link

OpakAlex commented Aug 1, 2023

+1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants