Closed Infra-Red closed 3 years ago
There are 4 types of acceptable inputs to the --buildpack
flag.
my-buildpack@1.2.3
./my-buildpack/
https://example.com/my-buildpack.tgz
gcr.io/my-image:latest
The first option, buildpack ID + version, is acceptable for buildpacks already in the builder (and in the near future via buildpack registry).
For images, as you've provide, the format is using the standard OCI image format. <hostname:>/<repo>[:<tag>]
Hope this helps demystify how this works. If you have any suggesting for future clarification that can be added to the help screen, we'd love to hear it.
I would suggest to extend the help message for the buildpack reference and for the image name with additional examples as you showed in the post above. I can submit a PR if you agree with this.
That would be great, @Infra-Red ! More help on documentation is always appreciated.
@dfreilich @jromero Please review when you can https://github.com/buildpacks/pack/pull/894. Thanks!
Summary
When I specify a buildpack version with the
--buildpack
flag for thepack build
command,pack
returns the following error saying that invalid buildpack string was provided.It works if I provide a buildpack version in the
buildpack:version
format, whilepack build --help
shows thatbuildpack@version
should be used.Which format should be used to specify a buildpack version when using
pack build
?Reproduction
Steps
Current behavior
pack
returns an error and tells me that invalid buildpack string was provided.Expected behavior
pack
should build the app using provided buildpack version.Environment
pack info
docker info