Closed teintuc closed 7 years ago
Note: from what I understood from the kubeclient code and thepuppet-swagger-generator code, apiVersion
(and kind
FWIW) shouldn't be properties of the types, as they are managed by kubeclient automatically.
This is tracked by garethr/puppet-swagger-generator#8.
When applying Kubernetes_Deployment resource:
It produces the following error:
The reason seems to come from puppet. A property name with an upper case letter is internally transformed to a snake case name at creation, but during property lookup it's missing the lower case operation and puppet can't find the property.
Changing manually the property to api_version makes it work for puppet but, of course, not for kubernetes. Might be the same problem with Kubernetes_Secrets on 'stringData' parameter.
The fix would be to camel case parameter's name when generating with swagger and snake case parameter's name when building the kubernetes api request.