no matches for kind "Deployment" in version "apps/v1"

5.7k views Asked by At

I have minikube v0.26.0 version and kubectl v1.10.1 version and localKube v1.8.0
i get the following error when i try to deploy the kubeless ui

$ kubectl create -f https://raw.githubusercontent.com/kubeless/kubeless-ui/master/k8s.yaml  

ERROR:

unable to recognize "https://raw.githubusercontent.com/kubeless/kubeless-ui/master/k8s.yaml": no matches for kind "Deployment" in version "apps/v1"

2

There are 2 answers

0
Abhishek D K On BEST ANSWER

after a long R & D

minikube start --logtostderr --v=0 --bootstrapper=localkube --vm-driver virtualbox  

now it downloaded the latest localkube version, and this solved my problem.

0
jkinkead On

As the comment says, you're using a version of Kubernetes that's very old. Deployment wasn't available under apps/v1 until Kubernetes 1.9, and you appear to be using 1.8.

If you want to solve this problem without upgrading your cluster, you'll need to replace the apiVersion value in all of your Deployment objects with one of the older paths:

apiVersion: apps/v1beta1
kind: Deployment

Note that while this will fix the immediate problem, you will still likely run into other compatibility issues, and should upgrade your cluster.