|
5 | 5 | "type": "object", |
6 | 6 | "definitions": { |
7 | 7 | "devContainerCommon": { |
| 8 | + "type": "object", |
8 | 9 | "properties": { |
9 | 10 | "name": { |
10 | 11 | "type": "string", |
|
18 | 19 | } |
19 | 20 | }, |
20 | 21 | "settings": { |
21 | | - "type": "object", |
| 22 | + "$ref": "vscode://schemas/settings/machine", |
22 | 23 | "description": "Machine specific settings that should be copied into the container." |
23 | 24 | }, |
24 | 25 | "postCreateCommand": { |
25 | | - "type": ["string", "array"], |
| 26 | + "type": [ |
| 27 | + "string", |
| 28 | + "array" |
| 29 | + ], |
26 | 30 | "description": "A command to run after creating the container. If this is a single string, it will be run in a shell. If this is an array of strings, it will be run as a single command without shell.", |
27 | 31 | "items": { |
28 | 32 | "type": "string" |
|
35 | 39 | } |
36 | 40 | }, |
37 | 41 | "nonComposeBase": { |
| 42 | + "type": "object", |
38 | 43 | "properties": { |
39 | 44 | "appPort": { |
40 | | - "type": ["integer", "string", "array"], |
| 45 | + "type": [ |
| 46 | + "integer", |
| 47 | + "string", |
| 48 | + "array" |
| 49 | + ], |
41 | 50 | "description": "Application ports that are exposed by the container. This can be a single port or an array of ports. Each port can be a number or a string. A number is mapped to the same port on the host. A string is passed to Docker unchanged and can be used to map ports differently, e.g. \"8000:8010\".", |
42 | 51 | "items": { |
43 | | - "type": ["integer", "string"] |
| 52 | + "type": [ |
| 53 | + "integer", |
| 54 | + "string" |
| 55 | + ] |
44 | 56 | } |
45 | 57 | }, |
46 | 58 | "runArgs": { |
|
52 | 64 | }, |
53 | 65 | "shutdownAction": { |
54 | 66 | "type": "string", |
55 | | - "enum": ["none", "stopContainer"], |
| 67 | + "enum": [ |
| 68 | + "none", |
| 69 | + "stopContainer" |
| 70 | + ], |
56 | 71 | "description": "Action to take when VS Code is shutting down. The default is to stop the container." |
57 | 72 | }, |
58 | 73 | "overrideCommand": { |
|
70 | 85 | } |
71 | 86 | }, |
72 | 87 | "dockerFileContainer": { |
| 88 | + "type": "object", |
73 | 89 | "properties": { |
74 | 90 | "dockerFile": { |
75 | 91 | "type": "string", |
|
80 | 96 | "description": "The location of the context folder for building the Docker image. The path is relative to the folder containing the `devcontainer.json` file." |
81 | 97 | } |
82 | 98 | }, |
83 | | - "required": ["dockerFile"] |
| 99 | + "required": [ |
| 100 | + "dockerFile" |
| 101 | + ] |
84 | 102 | }, |
85 | 103 | "imageContainer": { |
| 104 | + "type": "object", |
86 | 105 | "properties": { |
87 | 106 | "image": { |
88 | 107 | "type": "string", |
89 | 108 | "description": "The docker image that will be used to create the container." |
90 | 109 | } |
91 | 110 | }, |
92 | | - "required": ["image"] |
| 111 | + "required": [ |
| 112 | + "image" |
| 113 | + ] |
93 | 114 | }, |
94 | 115 | "composeContainer": { |
| 116 | + "type": "object", |
95 | 117 | "properties": { |
96 | 118 | "dockerComposeFile": { |
97 | | - "type": ["string", "array"], |
| 119 | + "type": [ |
| 120 | + "string", |
| 121 | + "array" |
| 122 | + ], |
98 | 123 | "description": "The name of the docker-compose file(s) used to start the services.", |
99 | 124 | "items": { |
100 | 125 | "type": "string" |
|
110 | 135 | }, |
111 | 136 | "shutdownAction": { |
112 | 137 | "type": "string", |
113 | | - "enum": ["none", "stopCompose"], |
| 138 | + "enum": [ |
| 139 | + "none", |
| 140 | + "stopCompose" |
| 141 | + ], |
114 | 142 | "description": "Action to take when VS Code is shutting down. The default is to stop the containers." |
115 | 143 | } |
116 | 144 | }, |
117 | | - "required": ["dockerComposeFile", "service", "workspaceFolder"] |
| 145 | + "required": [ |
| 146 | + "dockerComposeFile", |
| 147 | + "service", |
| 148 | + "workspaceFolder" |
| 149 | + ] |
118 | 150 | } |
119 | 151 | }, |
120 | 152 | "allOf": [ |
|
0 commit comments