You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I couldn't find any facilities in this library to load Kubernetes API objects from YAML files, something like this for the Java client.
Currently, I have to do it like this with js-yaml and fs:
constyaml=require('js-yaml');constfs=require('fs');constdeployment=yaml.safeLoad(fs.readFileSync('deployment.yml','utf8'));// ...in order to use it for:apiClient.createNamespacedDeployment('default',deployment,true);
Maybe it would be good to have a class for this, like in the Java client, or at least mention it in the README how it can be done with js-yaml.
The text was updated successfully, but these errors were encountered:
weibeld
changed the title
Load YAML files
Support for loading YAML files
Oct 18, 2018
Uh oh!
There was an error while loading. Please reload this page.
I couldn't find any facilities in this library to load Kubernetes API objects from YAML files, something like this for the Java client.
Currently, I have to do it like this with
js-yaml
andfs
:Maybe it would be good to have a class for this, like in the Java client, or at least mention it in the README how it can be done with
js-yaml
.The text was updated successfully, but these errors were encountered: