fix(core): update
This commit is contained in:
parent
eb6f7889d0
commit
6acbe30e2e
@ -12,8 +12,16 @@ export class DockerHost {
|
|||||||
* the constructor to instantiate a new docker sock instance
|
* the constructor to instantiate a new docker sock instance
|
||||||
* @param pathArg
|
* @param pathArg
|
||||||
*/
|
*/
|
||||||
constructor(pathArg: string = 'http://unix:/var/run/docker.sock:') {
|
constructor(pathArg?: string) {
|
||||||
this.socketPath = pathArg;
|
let pathToUse: string;
|
||||||
|
if (pathArg) {
|
||||||
|
pathToUse = pathArg;
|
||||||
|
} else if (process.env.CI) {
|
||||||
|
pathToUse = 'tcp://docker:2375/';
|
||||||
|
} else {
|
||||||
|
pathToUse = 'http://unix:/var/run/docker.sock:';
|
||||||
|
}
|
||||||
|
this.socketPath = pathToUse;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user