Auto-DevOps Error: "cannot unmarshal string into Go value of type struct"
Internal Zendesk ticket: https://gitlab.zendesk.com/agent/tickets/83539
I'm seeing an error with the Auto-DevOps feature. I've setup a branch new project based on the NodeJS project template. I then removed the
.gitlab_ci.yml
file from that project template, connected the project to our Kubernetes instance and committed a change to the README.md file to another branch to trigger a deploy to the review environment and encountered an error on theensure_namespace
function. Presumably, the output from our version of K8 isn't what's expected by the auto-devops scripts.
Kubernetes Version Information:
kubectl version
Client Version: version.Info{Major:"1", Minor:"7", GitVersion:"v1.7.4", GitCommit:"793658f2d7ca7f064d2bdf606519f9fe1229c 381", GitTreeState:"clean", BuildDate:"2017-08-17T08:48:23Z", GoVersion:"go1.8.3", Compiler:"gc", Platform:"linux/amd64" } Server Version: version.Info{Major:"1", Minor:"7+", GitVersion:"v1.7.7-rancher1", GitCommit:"a1ea37c6f6d21f315a07631b17b 9537881e1986a", GitTreeState:"clean", BuildDate:"2017-10-02T21:33:08Z", GoVersion:"go1.8.3", Compiler:"gc", Platform:"li nux/amd64"}
Here's the error the customer is seeing in the logs:
```bash
.
.
.
Update Complete. ⎈Happy Helming!⎈
Saving 1 charts
Downloading postgresql from repo https://kubernetes-charts.storage.googleapis.com/
Deleting outdated charts
[32;1m$ ensure_namespace[0;m
error: couldn't get version/kind; json parse error: json: cannot unmarshal string into Go value of type struct { APIVersion string "json:\"apiVersion,omitempty\""; Kind string "json:\"kind,omitempty\"" }
error: serializer for text/html doesn't exist
[31;1mERROR: Job failed: exit code 1