Fix kuberentes env var

pull/310/head
Frostebite 2022-01-30 01:17:18 +00:00
parent e7676d04ac
commit 6f543a5ec2
3 changed files with 11 additions and 3 deletions

6
dist/index.js vendored
View File

@ -2146,7 +2146,11 @@ class KubernetesJobSpecFactory {
}, },
}, },
env: [ env: [
...environment, ...environment.map((x) => {
const environmentVariable = new client_node_1.V1EnvVar();
environmentVariable.name = x.name;
environmentVariable.value = x.value;
}),
...secrets.map((x) => { ...secrets.map((x) => {
const secret = new client_node_1.V1EnvVarSource(); const secret = new client_node_1.V1EnvVarSource();
secret.secretKeyRef = new client_node_1.V1SecretKeySelector(); secret.secretKeyRef = new client_node_1.V1SecretKeySelector();

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

View File

@ -113,7 +113,11 @@ class KubernetesJobSpecFactory {
}, },
}, },
env: [ env: [
...environment, ...environment.map((x) => {
const environmentVariable = new V1EnvVar();
environmentVariable.name = x.name;
environmentVariable.value = x.value;
}),
...secrets.map((x) => { ...secrets.map((x) => {
const secret = new V1EnvVarSource(); const secret = new V1EnvVarSource();
secret.secretKeyRef = new V1SecretKeySelector(); secret.secretKeyRef = new V1SecretKeySelector();