From 10e5276c0ec89f2cb349bb8fe8421ae03f0af72a Mon Sep 17 00:00:00 2001 From: Stephen J Day Date: Tue, 9 Dec 2014 14:19:38 -0800 Subject: [PATCH] Add error code for unknown repository --- errors.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/errors.go b/errors.go index 9593741db..17758f44c 100644 --- a/errors.go +++ b/errors.go @@ -34,6 +34,9 @@ const ( // match the provided tag. ErrorCodeInvalidTag + // ErrorCodeUnknownRepository when the repository name is not known. + ErrorCodeUnknownRepository + // ErrorCodeUnknownManifest returned when image manifest name and tag is // unknown, accompanied by a 404 status. ErrorCodeUnknownManifest @@ -64,6 +67,7 @@ var errorCodeStrings = map[ErrorCode]string{ ErrorCodeInvalidLength: "INVALID_LENGTH", ErrorCodeInvalidName: "INVALID_NAME", ErrorCodeInvalidTag: "INVALID_TAG", + ErrorCodeUnknownRepository: "UNKNOWN_REPOSITORY", ErrorCodeUnknownManifest: "UNKNOWN_MANIFEST", ErrorCodeInvalidManifest: "INVALID_MANIFEST", ErrorCodeUnverifiedManifest: "UNVERIFIED_MANIFEST", @@ -78,6 +82,7 @@ var errorCodesMessages = map[ErrorCode]string{ ErrorCodeInvalidLength: "provided length did not match content length", ErrorCodeInvalidName: "manifest name did not match URI", ErrorCodeInvalidTag: "manifest tag did not match URI", + ErrorCodeUnknownRepository: "repository not known to registry", ErrorCodeUnknownManifest: "manifest not known", ErrorCodeInvalidManifest: "manifest is invalid", ErrorCodeUnverifiedManifest: "manifest failed signature validation",