images::check
Tag 14: a client names an image by digest and references and says where the server is to look, among its own images and the registries; the server sends exactly one response stating whether a source asked has the image, that no source was asked, or an error, and the scope finishes.
A client opens the scope with a request whose payload is the tag byte
14 followed by the image’s digest and references, and the sources
the server is to look in. The server sends exactly one response,
which is the answer, the word that no source was asked, or an error.
The response finish follows the response, and no frame follows the
finish.
- The request. The request names a manifest digest and zero or more references, each a registry host and a repository path, and states which of two sources the server is to look in. The digest identifies the image; a reference states where the client knows the bytes to be. Request states its form.
- The sources.
clientis the images the client built on the server by images::build and has not deleted, and no image another client built.registriesis every referenced registry the server’s policy lists, asked as<registry>/<name>@<digest>; the server ignores a reference naming a registry its policy does not list, and a request naming no reference asks nothing of this source. Either or both may be asked. The server looks in the client’s own images, where asked, before it asks a registry, and asks a registry only when the client’s own images, where asked, do not have the image. - Never the server’s own. The images the server holds on its own account, which no client built, are not a source. The server does not look among them, and does not answer available on account of one, whatever the request asks.
- The answer. The answer is exactly
{"type":"available"}or exactly{"type":"unavailable"}. The available answer states that at least one source asked has the image, at the time of the answer, for a container request naming that digest. The unavailable answer states that no source asked has it; a container request naming the image may still succeed where the client holds the image and the server obtains it from the client, or where a source not asked has it. Neither answer states which source. Response states their form. - No source. A source the server has is
clientwhere the server holds out theimages_storecapability, andregistrieswhere itsimages_registriesis not empty. A request that asks for neither source, or that asks only for sources the server has not, is answered with the byte2alone. The server looks nowhere, and nothing is determined about the image. A request that asks for a source the server has and a source it has not is answered from the source it has alone. - The error. An error states that the server did not answer the question, and that nothing was determined about the image. An error is not an unavailable answer.