We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 7b9be85 + 05a41df commit c4c6f4bCopy full SHA for c4c6f4b
.gitignore
@@ -51,6 +51,7 @@ typings/
51
52
# Optional npm cache directory
53
.npm
54
+.npmrc
55
56
# Optional eslint cache
57
.eslintcache
example/example.js
@@ -64,7 +64,7 @@ async function main() {
64
65
// Setup Kubernetes client.
66
const kubeConfig = new k8s.KubeConfig();
67
- kubeConfig.loadFromString(configResponse.result);
+ kubeConfig.loadFromString(typeof configResponse.result === "string" ? configResponse.result : JSON.stringify(configResponse.result));
68
const kubeClient = kubeConfig.makeApiClient(k8s.CoreV1Api);
69
const { namespace } = kubeConfig.getCurrentContextObject();
70
0 commit comments