@travetto/exec
Advanced tools
Comparing version 0.0.20 to 0.0.21
@@ -17,3 +17,3 @@ { | ||
}, | ||
"version": "0.0.20" | ||
"version": "0.0.21" | ||
} |
@@ -35,2 +35,3 @@ import * as child_process from 'child_process'; | ||
private env: { [key: string]: string } = {}; | ||
private ports: { [key: string]: number } = {}; | ||
@@ -70,2 +71,7 @@ public volumes: { [key: string]: string } = {}; | ||
addEnvVar(key: string, value: string) { | ||
this.env[key] = value; | ||
return this; | ||
} | ||
addVolume(local: string, container: string) { | ||
@@ -133,2 +139,5 @@ this.volumes[local] = container; | ||
} | ||
for (const k of Object.keys(this.env)) { | ||
finalArgs.push('-e', `"${k}=${this.env[k]}"`); | ||
} | ||
@@ -135,0 +144,0 @@ console.debug('Running', [...finalArgs, this.image, ...args]); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
17967
576