Error messages on each command for kubectl

9/26/2019

I want to use kubernetes on an ubuntu machine for development purpose (deployment/test) where I just want to run containers. So I installed kubectl following the kubernetes manual and when that didn't work I tried some others (native package and snap) but still get the same errors.

On each command I run I get an error, for example:

kubectl version
Client Version: version.Info{Major:"1", Minor:"16", GitVersion:"v1.16.0", GitCommit:"2bd9643cee5b3b3a5ecbd3af49d09018f0773c77", GitTreeState:"clean", BuildDate:"2019-09-18T14:36:53Z", GoVersion:"go1.12.9", Compiler:"gc", Platform:"linux/amd64"}
error: unable to parse the server version: invalid character '<' looking for beginning of value

or

kubectl get services
error: yaml: line 3: mapping values are not allowed in this context

I don't know if it has something to do with it but the same machine is running Gitlab among other things. I haven't done any configuration on kubectl.

How can I find the source of these errors?

-- BvdVen
kubectl
kubernetes
ubuntu
yaml

1 Answer

9/26/2019

There is a may possibility of running another application on same port localhost:8080. 8080 default used by kubectl.

for more info please have a look at this : Fresh macos install - kubectl outputs error message

-- Harsh Manvar
Source: StackOverflow