export type LogLevel = 'error' | 'warn' | 'info' | 'http' | 'verbose' | 'debug' | 'silly'; export type MemoryUnit = 'E' | 'P' | 'T' | 'G' | 'M' | 'k' | 'Ei' | 'Pi' | 'Ti' | 'Gi' | 'Mi' | 'Ki'; export type BandwidthUnit = 'bit' | 'kbit' | 'mbit' | 'gbit' | 'tbit' | 'bps' | 'kbps' | 'mbps' | 'gbps' | 'tbps' | 'kibit' | 'mibit' | 'gibit' | 'tibit' | 'kibps' | 'mibps' | 'gibps' | 'tibps'; export type CpuUnit = 'cpuunit' | 'milicpu'; export type TimeUnits = 's' | 'ms' | 'us'; export interface Instance { setNetworkControl(config: { bandwidth?: { value: number; unit: BandwidthUnit; }; delay?: { value: number; unit: TimeUnits; }; lossRate?: number; duplicateRate?: number; corruptionRate?: number; }): Promise; clearAllNetworkLimitations(): Promise; readonly memoryLimit?: { value: number; unit: MemoryUnit; }; readonly cpuLimit?: { value: number; unit: CpuUnit; }; readonly healthCheckUrl: string | undefined; readonly endpoints: Endpoint[]; hostname?: string; endPointUrl?: string; deploymentName?: string; } export type ContainerImage = { image: string; pullSecret?: { [registrydomain: string]: { username: string; password: string; }; }; }; export type ReadinessProbe = { failureThreshold: number; httpGet: { path: string; port: number; scheme: string; }; initialDelaySeconds: number; periodSeconds: number; successThreshold: number; timeoutSeconds: number; }; export interface EnvironmentControllerInterface { deployInstance(instance: T): Promise; deployContainerizedService(name: string, image: ContainerImage, endpoints: Endpoint[], readinessProbe?: ReadinessProbe): Promise; tearDown(): void; } export type Endpoint = { name: string; path: string; port: number; };