1 | export interface DockerFileAnalysis {
|
2 | baseImage?: string;
|
3 | dockerfilePackages: DockerFilePackages;
|
4 | dockerfileLayers: DockerFileLayers;
|
5 | error?: {
|
6 | code: DockerFileAnalysisErrorCode;
|
7 | };
|
8 | }
|
9 |
|
10 | export enum DockerFileAnalysisErrorCode {
|
11 | BASE_IMAGE_NAME_NOT_FOUND = "BASE_IMAGE_NAME_NOT_FOUND",
|
12 | BASE_IMAGE_NON_RESOLVABLE = "BASE_IMAGE_NON_RESOLVABLE",
|
13 | }
|
14 |
|
15 | export interface DockerFilePackages {
|
16 | [packageName: string]: {
|
17 | instruction: string;
|
18 | installCommand: string;
|
19 | };
|
20 | }
|
21 |
|
22 | export interface DockerFileLayers {
|
23 | [id: string]: {
|
24 | instruction: string;
|
25 | };
|
26 | }
|
27 |
|
28 | export interface GetDockerfileBaseImageNameResult {
|
29 | baseImage?: string;
|
30 | error?: GetDockerfileBaseImageNameResultError;
|
31 | }
|
32 |
|
33 | export interface GetDockerfileBaseImageNameResultError {
|
34 | code: DockerFileAnalysisErrorCode;
|
35 | }
|
36 |
|
37 | export interface UpdateDockerfileBaseImageNameResult {
|
38 | contents: string;
|
39 | error?: UpdateDockerfileBaseImageNameError;
|
40 | }
|
41 |
|
42 | export interface UpdateDockerfileBaseImageNameError {
|
43 | code: UpdateDockerfileBaseImageNameErrorCode;
|
44 | }
|
45 |
|
46 | export enum UpdateDockerfileBaseImageNameErrorCode {
|
47 | BASE_IMAGE_NAME_FRAGMENTED = "BASE_IMAGE_NAME_FRAGMENTED",
|
48 | BASE_IMAGE_NAME_NOT_FOUND = "BASE_IMAGE_NAME_NOT_FOUND",
|
49 | DOCKERFILE_GENERATION_FAILED = "DOCKERFILE_GENERATION_FAILED",
|
50 | }
|