Skip to content

Commit 80e72bc

Browse files
committed
annotations.md: label schema compatibility table
Provided a conversion table to describe the equivalent values between label-schema.org and OCI image annotations. Some values are clarified. The human-readable `name` and `description` have also been added. Signed-off-by: Stephen J Day <[email protected]>
1 parent 3437101 commit 80e72bc

File tree

1 file changed

+29
-4
lines changed

1 file changed

+29
-4
lines changed

annotations.md

Lines changed: 29 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,38 @@ This property contains arbitrary metadata.
1717
## Pre-Defined Annotation Keys
1818

1919
This specification defines the following annotation keys, intended for but not limited to [image index](image-index.md) and image [manifest](manifest.md) authors:
20-
* **org.opencontainers.image.created** date on which the image was built (string, date-time as defined by [RFC 3339](https://tools.ietf.org/html/rfc3339#section-5.6)).
20+
* **org.opencontainers.image.created** date and time on which the image was built (string, date-time as defined by [RFC 3339](https://tools.ietf.org/html/rfc3339#section-5.6)).
2121
* **org.opencontainers.image.authors** contact details of the people or organization responsible for the image (freeform string)
22-
* **org.opencontainers.image.homepage** URL to find more information on the image (string, a URL with scheme HTTP or HTTPS)
22+
* **org.opencontainers.image.url** URL to find more information on the image (string, a URL with scheme HTTP or HTTPS)
2323
* **org.opencontainers.image.documentation** URL to get documentation on the image (string, a URL with scheme HTTP or HTTPS)
2424
* **org.opencontainers.image.source** URL to get source code for the binary files in the image (string, a URL with scheme HTTP or HTTPS)
25-
* **org.opencontainers.image.version** [Semantic versioning-compatible](http://semver.org/) version of the packaged software.
26-
* **org.opencontainers.image.revision** Source control revision identifier for packaged software.
25+
* **org.opencontainers.image.version** [Semantic versioning-compatible](http://semver.org/) version of the packaged software. The version MAY match a label or tag in the source code repository.
26+
* **org.opencontainers.image.revision** Source control revision identifier for the packaged software.
2727
* **org.opencontainers.image.vendor** Name of the distributing entity, organization or individual.
2828
* **org.opencontainers.image.licenses** Comma-separated list of licenses under which contained software is distributed, in [SPDX Short identifier]https://spdx.org/licenses/] form.
2929
* **org.opencontainers.image.ref.name** Name of the reference for a target (string). SHOULD only be considered valid when on descriptors on `index.json` within [image layout](image-layout.md).
30+
* **org.opencontainers.image.name** Human-readable name of the software packaged in the image (string)
31+
* **org.opencontainers.image.description** Human-readable description of the software packaged in the image (string)
32+
33+
## Back-compatibility with Label Schema
34+
35+
[Label Schema](https://label-schema.org) defined a number of conventional labels for container images, and these are now superceded by annotations with keys starting **org.opencontainers.image**.
36+
37+
While users are encouraged to use the **org.opencontainers.image** keys, tools MAY choose to support compatible annotations using the **org.label-schema** prefix as follows.
38+
39+
| `org.opencontainers.image` prefix | `org.label-schema prefix` | Compatibility notes |
40+
|---------------------------|-------------------------|---------------------|
41+
| `created` | `build-date` | Compatible |
42+
| `url` | `url` | Compatible |
43+
| `source` | `vcs-url` | Compatible |
44+
| `version` | `version` | Compatible |
45+
| `revision` | `vcs-ref` | Compatible |
46+
| `vendor` | `vendor` | Compatible |
47+
| `name` | `name` | Compatible |
48+
| `description` | `description` | Compatible |
49+
| `documentation` | `usage` | Value is compatible if the documentation is located by a URL |
50+
| `authors` | | No equivalent in Label Schema |
51+
| `licenses` | | No equivalent in Label Schema |
52+
| `ref.name` | | No equivalent in Label Schema |
53+
| | `schema-version`| No equivalent in the OCI Image Spec |
54+
| | `docker.*`, `rkt.*` | No equivalent in the OCI Image Spec |

0 commit comments

Comments
 (0)