mirror of
https://github.com/ditkrg/k8s-set-context.git
synced 2026-01-22 22:06:49 +00:00
adding spike env var
This commit is contained in:
parent
2f6bfda1e2
commit
4da86321ca
@ -9,7 +9,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
||||
});
|
||||
};
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.run = void 0;
|
||||
const core = require("@actions/core");
|
||||
const path = require("path");
|
||||
const fs = require("fs");
|
||||
@ -114,9 +113,9 @@ function run() {
|
||||
fs.writeFileSync(kubeconfigPath, kubeconfig);
|
||||
fs.chmodSync(kubeconfigPath, '600');
|
||||
core.exportVariable('KUBECONFIG', kubeconfigPath);
|
||||
core.exportVariable('DockerFilePath', 'DockerFilePath/from/input');
|
||||
console.log('KUBECONFIG environment variable is set');
|
||||
yield setContext(kubeconfigPath);
|
||||
});
|
||||
}
|
||||
exports.run = run;
|
||||
run().catch(core.setFailed);
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
"private": true,
|
||||
"main": "lib/run.js",
|
||||
"scripts": {
|
||||
"build": "tsc --outDir .\\lib\\ --rootDir .\\src\\"
|
||||
"build": "tsc --outDir ./lib/ --rootDir ./src/"
|
||||
},
|
||||
"keywords": [
|
||||
"actions",
|
||||
|
||||
@ -109,6 +109,7 @@ async function run() {
|
||||
fs.writeFileSync(kubeconfigPath, kubeconfig);
|
||||
fs.chmodSync(kubeconfigPath, '600');
|
||||
core.exportVariable('KUBECONFIG', kubeconfigPath);
|
||||
core.exportVariable('DockerFilePath', 'DockerFilePath/from/input');
|
||||
console.log('KUBECONFIG environment variable is set');
|
||||
await setContext(kubeconfigPath);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user