cmd/oci-image-tool: validate all refs by default#279
cmd/oci-image-tool: validate all refs by default#279philips merged 1 commit intoopencontainers:masterfrom
Conversation
image/descriptor.go
Outdated
| return pts[1] | ||
| } | ||
|
|
||
| func findDescriptors(w walker) (map[string]*descriptor, error) { |
There was a problem hiding this comment.
Maybe listReferences? In #159, the analogous function is refs.Engine.List().
|
On Thu, Sep 08, 2016 at 06:52:45AM -0700, Antonio Murdaca wrote:
Update the man page too. |
|
@runcom If unknown types are encountered, what is the intended behavior? I ask because we do need to be able to have references to unknown things but still pass validation. This will make it easier to extend in the future. |
|
On Thu, Sep 08, 2016 at 12:47:36PM -0700, Stephen Day wrote:
I think we need to error with “not implemented”-level errors.
That makes sense. We might want an --ignore-unknown-media-types flag What happens if you recognize the ref type |
|
On Thu, Sep 08, 2016 at 01:00:21PM -0700, Stephen Day wrote:
Sure. I was just linking in previous unrecognized-type discussion to |
|
@stevvooe right now, if the media type is unknown the tool errors out. We should at least soften that to just print a warning. This behavior is in the |
|
On Thu, Sep 08, 2016 at 01:58:18PM -0700, Antonio Murdaca wrote:
I'm fine punting unrecognized media type issues to follow up work, |
|
@runcom SGTM. Please open an issue. |
5c9400d to
fde1e4d
Compare
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
fde1e4d to
a480306
Compare
|
LGTM. |
| // Validate walks through the given .tar file and | ||
| // validates the manifest pointed to by the given refs | ||
| // or returns an error if the validation failed. | ||
| //iiii or returns an error if the validation failed. |
|
LGTM, with one small nit |
|
LGTM |
This is taking care of #271 (comment) (left a TODO/FIXME for later in case).
I'll adapt everything to be same as per #266 later
/cc @wking @vbatts @philips @stevvooe
Signed-off-by: Antonio Murdaca runcom@redhat.com