Skip to content

Commit 94291a9

Browse files
committed
Merge pull request #564 from xiekeyang/config-schema
move defs-config.json to config-schema.json
2 parents bf74b66 + ab9f411 commit 94291a9

File tree

3 files changed

+946
-760
lines changed

3 files changed

+946
-760
lines changed

schema/config-schema.json

Lines changed: 102 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,114 @@
1818
"type": "string"
1919
},
2020
"config": {
21-
"$ref": "defs-config.json#/definitions/config"
21+
"type": "object",
22+
"properties": {
23+
"User": {
24+
"type": "string"
25+
},
26+
"ExposedPorts": {
27+
"$ref": "defs.json#/definitions/mapStringObject"
28+
},
29+
"Env": {
30+
"type": "array",
31+
"items": {
32+
"type": "string"
33+
}
34+
},
35+
"Entrypoint": {
36+
"oneOf": [
37+
{
38+
"type": "array",
39+
"items": {
40+
"type": "string"
41+
}
42+
},
43+
{
44+
"type": "null"
45+
}
46+
]
47+
},
48+
"Cmd": {
49+
"oneOf": [
50+
{
51+
"type": "array",
52+
"items": {
53+
"type": "string"
54+
}
55+
},
56+
{
57+
"type": "null"
58+
}
59+
]
60+
},
61+
"Volumes": {
62+
"oneOf": [
63+
{
64+
"$ref": "defs.json#/definitions/mapStringObject"
65+
},
66+
{
67+
"type": "null"
68+
}
69+
]
70+
},
71+
"WorkingDir": {
72+
"type": "string"
73+
},
74+
"Labels": {
75+
"oneOf": [
76+
{
77+
"$ref": "defs.json#/definitions/mapStringString"
78+
},
79+
{
80+
"type": "null"
81+
}
82+
]
83+
}
84+
}
2285
},
2386
"rootfs": {
24-
"$ref": "defs-config.json#/definitions/rootfs"
87+
"type": "object",
88+
"properties": {
89+
"diff_ids": {
90+
"type": "array",
91+
"items": {
92+
"type": "string"
93+
}
94+
},
95+
"type": {
96+
"type": "string",
97+
"enum": [
98+
"layers"
99+
]
100+
}
101+
},
102+
"required": [
103+
"diff_ids",
104+
"type"
105+
]
25106
},
26107
"history": {
27108
"type": "array",
28109
"items": {
29-
"$ref": "defs-config.json#/definitions/history"
110+
"type": "object",
111+
"properties": {
112+
"created": {
113+
"type": "string",
114+
"format": "date-time"
115+
},
116+
"author": {
117+
"type": "string"
118+
},
119+
"created_by": {
120+
"type": "string"
121+
},
122+
"comment": {
123+
"type": "string"
124+
},
125+
"empty_layer": {
126+
"type": "boolean"
127+
}
128+
}
30129
}
31130
}
32131
},

schema/defs-config.json

Lines changed: 0 additions & 113 deletions
This file was deleted.

0 commit comments

Comments
 (0)