Skip to content

Commit acd8a30

Browse files
committed
schema/defs-image: Remove 'null' from valid annotations
The 'null' option has been in the JSON Schema since 78c7ff7 (manifest: add annotations, 2016-04-27, opencontainers#44), although I expect it was accidental. The spec has clearly not allowed: "annotations": null since 873b9b6 (Add some text about extensions, 2016-06-26, opencontainers#164) landed with the following (still current) requirements: Annotations MUST be a key-value map where both the key and value MUST be strings. and: If there are no annotations then this property MUST either be absent or be an empty map. Folks without annotations should not set the property at all, or they should set it to: "annotations": {} Signed-off-by: W. Trevor King <[email protected]>
1 parent 00850ec commit acd8a30

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

schema/defs-image.json

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -83,14 +83,7 @@
8383
},
8484
"annotations": {
8585
"id": "https://opencontainers.org/schema/image/annotations",
86-
"oneOf": [
87-
{
88-
"$ref": "defs.json#/definitions/mapStringString"
89-
},
90-
{
91-
"type": "null"
92-
}
93-
]
86+
"$ref": "defs.json#/definitions/mapStringString"
9487
}
9588
}
9689
}

0 commit comments

Comments
 (0)