Documentation
¶
Index ¶
- Constants
- func DefaultBuildpackStacks() []string
- type Buildpack
- type Buildpacks
- type IDDictionary
- type Passthrough
- type ShimmedBuildpack
- type Shimmer
- func (shimmer *Shimmer) Apply(ctx context.Context, buildpacks []string) (Buildpacks, IDDictionary, error)
- func (shimmer *Shimmer) BuildpackAPIVersion() string
- func (shimmer *Shimmer) BuildpackStacks() []string
- func (shimmer *Shimmer) CnbShimVersion() string
- func (shimmer *Shimmer) InstallSources(sources []sources.Source)
- type UnpackedBuildpack
Constants ¶
const DefaultBuildpackAPIVersion = "0.4"
DefaultBuildpackAPIVersion the default API version to write to buildpack.toml
const DefaultCnbShimVersion = "0.2"
DefaultCnbShimVersion the default cnb-shim version to use
Variables ¶
This section is empty.
Functions ¶
func DefaultBuildpackStacks ¶
func DefaultBuildpackStacks() []string
DefaultBuildpackStacks the stacks to write to buildpack.toml
Types ¶
type Buildpack ¶
type Buildpack interface {
PackArgument() string
}
Buildpack implements PackArgument for the underlying buildpack
type Buildpacks ¶
type Buildpacks []Buildpack
Buildpacks slice of buildpacks with shim applied
func (Buildpacks) PackArguments ¶
func (buildpacks Buildpacks) PackArguments() []string
PackArguments returns the arguments for the pack command
type IDDictionary ¶
IDDictionary buildpack ID dictionary, each key is the original buildpack ID and the value is what it was replaced for during the shim process
type Passthrough ¶
type Passthrough struct {
Buildpack string
}
Passthrough is a buildpack that reports the cnb pack argument as the same reported buildpack, useful in buildpack references such as "heroku/go" which buildpacker does not apply any shim
func (*Passthrough) PackArgument ¶
func (pt *Passthrough) PackArgument() string
PackArgument return argument for passthrough
type ShimmedBuildpack ¶
type ShimmedBuildpack struct {
UnpackedBuildpack
}
ShimmedBuildpack holds information about a shimmed buildpack
func (ShimmedBuildpack) ShimBuildpackToml ¶
func (shimmed ShimmedBuildpack) ShimBuildpackToml() string
ShimBuildpackToml returns the path to the buildpack.toml of the shim
type Shimmer ¶
type Shimmer struct { Sources []sources.Source APIVersion string Stacks []string ShimVersion string }
Shimmer shims all the specified buildpacks
func (*Shimmer) Apply ¶
func (shimmer *Shimmer) Apply(ctx context.Context, buildpacks []string) (Buildpacks, IDDictionary, error)
Apply prepares all the specified buildpacks with a shim and returns path to local directories with shim applied
func (*Shimmer) BuildpackAPIVersion ¶
BuildpackAPIVersion the BuildpackAPIVersion to use in buildpack.toml
func (*Shimmer) BuildpackStacks ¶
BuildpackStacks the stacks to use in buildpack.toml
func (*Shimmer) CnbShimVersion ¶
CnbShimVersion returns the cnb-shim version to use
func (*Shimmer) InstallSources ¶
InstallSources installs a list of sources
type UnpackedBuildpack ¶
UnpackedBuildpack unpacked buildpack
func (UnpackedBuildpack) PackArgument ¶
func (unpacked UnpackedBuildpack) PackArgument() string
PackArgument returns the argument for the pack command
func (UnpackedBuildpack) TargetDir ¶
func (unpacked UnpackedBuildpack) TargetDir() string
TargetDir returns the target dir of a shimmed buildpack