vmware-archive / kubecfg

A tool for managing complex enterprise Kubernetes environments as code.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Validate command didn't report error, but kubctl report error

wd opened this issue · comments

When I add an annotation managed-by-kubecfg to my deployment, and set its value to true(boolean, not string)

$ kubecfg validate  sandbox/main.jsonnet
INFO  Validating deployments sandbox.simple-deploy
INFO  validate object "apps/v1, Kind=Deployment"

$ kubecfg show  sandbox/main.jsonnet | kubectl diff -f-
error: unable to decode "STDIN": resource.metadataOnlyObject.ObjectMeta: v1.ObjectMeta.Annotations: ReadString: expects " or n, but found t, error found in #10 byte of ...|kubecfg":true},"labe|..., bigger context ...
|environment":"sandbox","managed-by-kubecfg":true},"labels":{"name":"simple-deploy"},"name":"sim|...

The validate and update command didn't report errors which should be. kubectl report the error correctly.