-
Notifications
You must be signed in to change notification settings - Fork 522
/
DockerRunTaskDefinitionBase.ts
47 lines (41 loc) · 1.41 KB
/
DockerRunTaskDefinitionBase.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See LICENSE.md in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { ShellQuotedString } from 'vscode';
import { PlatformOS } from '../utils/platform';
import { DockerLabels, TaskDefinitionBase } from './TaskDefinitionBase';
export interface DockerContainerExtraHost {
hostname: string;
ip: string;
}
export interface DockerContainerPort {
hostPort?: number;
containerPort: number;
protocol?: 'tcp' | 'udp';
}
export interface DockerContainerVolume {
localPath: string;
containerPath: string;
permissions?: 'ro' | 'rw';
}
export interface DockerRunOptions {
command?: string | ShellQuotedString[];
containerName?: string;
entrypoint?: string;
env?: { [key: string]: string };
envFiles?: string[];
extraHosts?: DockerContainerExtraHost[];
image?: string;
labels?: DockerLabels;
network?: string;
networkAlias?: string;
os?: PlatformOS;
ports?: DockerContainerPort[];
portsPublishAll?: boolean;
volumes?: DockerContainerVolume[];
remove?: boolean;
}
export interface DockerRunTaskDefinitionBase extends TaskDefinitionBase {
dockerRun?: DockerRunOptions;
}