BREAKING CHANGE(DockerHost): Rename DockerHost constructor option dockerSockPath to socketPath and update internal socket path handling
This commit is contained in:
@@ -3,6 +3,6 @@
|
||||
*/
|
||||
export const commitinfo = {
|
||||
name: '@apiclient.xyz/docker',
|
||||
version: '1.3.6',
|
||||
version: '2.0.0',
|
||||
description: 'Provides easy communication with Docker remote API from Node.js, with TypeScript support.'
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ export interface IAuthData {
|
||||
}
|
||||
|
||||
export interface IDockerHostConstructorOptions {
|
||||
dockerSockPath?: string;
|
||||
socketPath?: string;
|
||||
imageStoreDir?: string;
|
||||
}
|
||||
|
||||
@@ -44,8 +44,8 @@ export class DockerHost {
|
||||
...optionsArg,
|
||||
};
|
||||
let pathToUse: string;
|
||||
if (optionsArg.dockerSockPath) {
|
||||
pathToUse = optionsArg.dockerSockPath;
|
||||
if (optionsArg.socketPath) {
|
||||
pathToUse = optionsArg.socketPath;
|
||||
} else if (process.env.DOCKER_HOST) {
|
||||
pathToUse = process.env.DOCKER_HOST;
|
||||
} else if (process.env.CI) {
|
||||
|
||||
Reference in New Issue
Block a user