Kubeconfigs as file references (#466)

Signed-off-by: Jussi Nummelin <jussi.nummelin@gmail.com>
Co-authored-by: Lauri Nevala <lauri.nevala@gmail.com>
Co-authored-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
This commit is contained in:
authored and GitHub committed 2020-07-03 16:53:23 +03:00
1 parent c15aa7972c
commit 55687b7d35
23 files changed
+272 -162

No files matched your search

@@ -6,10 +6,10 @@ const state = {
}
const actions = {
reloadAvailableKubeContexts: ({commit}) => {
reloadAvailableKubeContexts({commit}, file) {
let kc = new k8s.KubeConfig();
try {
kc.loadFromDefault();
kc.loadFromFile(file);
} catch (error) {
console.error("Failed to read default kubeconfig: " + error.message);
}