@cto.ai/ops
Version:
💻 CTO.ai Ops - The CLI built for Teams 🚀
31 lines (30 loc) • 1.27 kB
TypeScript
/// <reference types="node" />
import Docker from 'dockerode';
import { ErrorService } from './Error';
import { OpCommand } from '../types';
export declare class ImageService {
protected error: ErrorService;
constructor(error?: ErrorService);
log: {
(message?: any, ...optionalParams: any[]): void;
(message?: any, ...optionalParams: any[]): void;
};
checkLocalImage: (opImageUrl: string) => Promise<string | undefined>;
imageFilterPredicate: (repo: string) => ({ RepoTags }: Docker.ImageInfo) => string | undefined;
pull: (op: OpCommand, authconfig: Docker.AuthConfig) => Promise<void>;
setParser: (op: OpCommand, getFn: (status: string, op: OpCommand) => {
speed: string;
}) => {
parser: import("stream").Transform;
bar: import("cli-progress").Bar;
};
getProgressBarText: (status: string, { name }: OpCommand) => {
speed: string;
};
updateStatusBar: (stream: NodeJS.ReadWriteStream, { parser, bar }: {
parser: any;
bar: any;
}) => (resolve: (data: any) => void, reject: (err: Error) => void) => Promise<void>;
checkIfDockerfileExists: (opPath: string) => boolean;
build: (tag: string, opPath: string, op: OpCommand) => Promise<void>;
}