Skip to content
This repository has been archived by the owner on May 3, 2022. It is now read-only.

duffle export should only try to export 'docker' and 'oci' images #733

Open
radu-matei opened this issue Apr 30, 2019 · 1 comment
Open
Milestone

Comments

@radu-matei
Copy link
Member

Trying to export a test bundle that also contains an image type that is neither docker, nor oci results in an error:

Error: Error preparing artifacts: Error pulling image c: Error response from daemon: pull access denied for c, repository does not exist or may require 'docker login'

Test bundle:

{
  "name": "testrelocate",
  "version": "0.1",
  "description": "a bundle with images",
  "invocationImages": [
    {
      "image": "technosophos/helloworld:0.1.0",
      "imageType": "docker"
    }
  ],
  "images": {
    "a": {
      "description": "digested oci",
      "image": "deislabs/duffle@sha256:4d41eeb38fb14266b7c0461ef1ef0b2f8c05f41cd544987a259a9d92cdad2540",
      "digest": "sha256:4d41eeb38fb14266b7c0461ef1ef0b2f8c05f41cd544987a259a9d92cdad2540",
      "imageType": "oci"
    },
    "b": {
      "description": "tagged docker",
      "image": "deislabs/duffle:0.1.0-ralpha.5-englishrose",
      "digest": "sha256:14d6134d892aeccb7e142557fe746ccd0a8f736a747c195ef04c9f3f0f0bbd49",
      "imageType": "docker"
    },
    "c": {
      "description": "neither oci nor docker",
      "image": "c",
      "imageType": "c"
    }
  }
}
@glyn
Copy link
Contributor

glyn commented Apr 30, 2019

If duffle was to ignore images with types other than oci and docker, then the exported bundle would be incomplete, so I suggest the safest fix to this issue is to fail with an error "unsupported image type: c". That would also allow for support for other image types to be added in the future without breaking backwards compatibility .

@jeremyrickard jeremyrickard added this to the Duffle 1.0 milestone Aug 12, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants