-
Notifications
You must be signed in to change notification settings - Fork 17
Description
package.toml (same with builder.toml) may contain non-docker-registry dependencies, say:
[buildpack]
uri = "./"
[[dependencies]]
uri = "https://www.example.com/my-buildpack.cnb"
[[dependencies]]
uri = "./a/local/directory"
[[dependencies]]
uri = "some/local/file.cnb"The docs say (https://buildpacks.io/docs/reference/config/package-config/):
uri: A URL or path to an archive, a packaged buildpack (saved as a .cnb file), or a directory. If path is relative, it must be relative to the package.toml.
and that all works brilliantly with pack - jam gets confused though.
Expected Behavior
for the above package.toml, jam update-buildpack exits successfully without doing anything
for a builder.toml with similar [[buildpacks]] entries, jam update-builder exists successfully without doing anything
Current Behavior
jam update-buildpack treats everything as a docker image reference and tries to get manifests ("failed to execute: failed to get buildpackage ID for ...")
jam update-builder treats everything as a docker image reference and tries to get tags ("failed to execute: failed to list tags: GET ... [map[Action:pull Class: Name:some/local/file.cnb Type:repository]]")
Possible Solution
parse uri as a URI and only contact a docker registry if it's a urn:cnb:registry:... or a docker:// URL
Steps to Reproduce
- add a non-docker
[[dependencies]]entry to apackage.tomland runjam update-buildpack - add a non-docker
[[buildpacks]]entry to abuilder.tomland runjam update-builder
Motivations
we're trying to use jam on builders/buildpacks that don't necessarily have every part coming in via a docker registry