Documentation ¶
Index ¶
- Constants
- Variables
- func PrependExtensions(orderBp buildpack.Order, orderExt buildpack.Order) buildpack.Order
- func ReadGroup(path string) (buildpack.Group, error)
- func ReadOrder(path string) (buildpack.Order, buildpack.Order, error)
- func SBOMExtensions() []string
- func TruncateSha(sha string) string
- type Analyzer
- type AnalyzerFactory
- type BuildEnv
- type Builder
- type BuildpackAPIVerifier
- type Cache
- type CacheHandler
- type ConfigHandler
- type DefaultConfigHandler
- type DefaultDetectResolver
- type DetectResolver
- type Detector
- type DetectorFactory
- type DirStore
- type DockerfileApplier
- type ExportOptions
- type Exporter
- type Extender
- type ExtenderFactory
- type GenerateResult
- type Generator
- type GeneratorFactory
- type ImageHandler
- type LauncherConfig
- type LayerDir
- type LayerFactory
- type MultiError
- type Platform
- type RebaseReport
- type Rebaser
- type RegistryHandler
- type Restorer
Constants ¶
View Source
const ( CodeDetectPass = 0 CodeDetectFail = 100 )
Variables ¶
View Source
var ( ErrFailedDetection = errors.New("no buildpacks participating") ErrBuildpack = errors.New("buildpack(s) failed with err") )
View Source
var Config = &DefaultConfigHandler{}
Functions ¶
func PrependExtensions ¶ added in v0.15.0
func SBOMExtensions ¶ added in v0.16.0
func SBOMExtensions() []string
func TruncateSha ¶
Types ¶
type Analyzer ¶
type Analyzer struct { PreviousImage imgutil.Image RunImage imgutil.Image Logger log.Logger SBOMRestorer layer.SBOMRestorer // Platform API < 0.7 Buildpacks []buildpack.GroupElement Cache Cache LayerMetadataRestorer layer.MetadataRestorer RestoresLayerMetadata bool }
type AnalyzerFactory ¶ added in v0.14.1
type AnalyzerFactory struct {
// contains filtered or unexported fields
}
func NewAnalyzerFactory ¶ added in v0.14.1
func NewAnalyzerFactory( platformAPI *api.Version, apiVerifier BuildpackAPIVerifier, cacheHandler CacheHandler, configHandler ConfigHandler, imageHandler ImageHandler, registryHandler RegistryHandler, ) *AnalyzerFactory
func (*AnalyzerFactory) NewAnalyzer ¶ added in v0.14.1
func (f *AnalyzerFactory) NewAnalyzer( additionalTags []string, cacheImageRef string, launchCacheDir string, layersDir string, legacyCacheDir string, legacyGroup buildpack.Group, legacyGroupPath string, outputImageRef string, previousImageRef string, runImageRef string, skipLayers bool, logger log.Logger, ) (*Analyzer, error)
type Builder ¶
type BuildpackAPIVerifier ¶ added in v0.15.0
type CacheHandler ¶ added in v0.14.1
type ConfigHandler ¶ added in v0.14.1
type DefaultConfigHandler ¶ added in v0.15.0
type DefaultConfigHandler struct{}
func NewConfigHandler ¶ added in v0.15.0
func NewConfigHandler() *DefaultConfigHandler
func (*DefaultConfigHandler) ReadAnalyzed ¶ added in v0.15.0
func (h *DefaultConfigHandler) ReadAnalyzed(path string) (platform.AnalyzedMetadata, error)
func (*DefaultConfigHandler) ReadGroup ¶ added in v0.15.0
func (h *DefaultConfigHandler) ReadGroup(path string) (buildpackGroup []buildpack.GroupElement, extensionsGroup []buildpack.GroupElement, err error)
type DefaultDetectResolver ¶ added in v0.16.0
func NewDefaultDetectResolver ¶ added in v0.16.0
func NewDefaultDetectResolver(logger log.Logger) *DefaultDetectResolver
func (*DefaultDetectResolver) Resolve ¶ added in v0.16.0
func (r *DefaultDetectResolver) Resolve(done []buildpack.GroupElement, detectRuns *sync.Map) ([]buildpack.GroupElement, []platform.BuildPlanEntry, error)
Resolve aggregates the detect output for a group of buildpacks and tries to resolve a build plan for the group. If any required buildpack in the group failed detection or a build plan cannot be resolved, it returns an error.
type DetectResolver ¶ added in v0.15.0
type DetectResolver interface {
Resolve(done []buildpack.GroupElement, detectRuns *sync.Map) ([]buildpack.GroupElement, []platform.BuildPlanEntry, error)
}
type Detector ¶ added in v0.11.0
type Detector struct { AppDir string BuildConfigDir string DirStore DirStore Executor buildpack.DetectExecutor HasExtensions bool Logger log.LoggerHandlerWithLevel Order buildpack.Order PlatformDir string Resolver DetectResolver Runs *sync.Map // contains filtered or unexported fields }
type DetectorFactory ¶ added in v0.15.0
type DetectorFactory struct {
// contains filtered or unexported fields
}
func NewDetectorFactory ¶ added in v0.15.0
func NewDetectorFactory( platformAPI *api.Version, apiVerifier BuildpackAPIVerifier, configHandler ConfigHandler, dirStore DirStore, ) *DetectorFactory
func (*DetectorFactory) NewDetector ¶ added in v0.15.0
func (f *DetectorFactory) NewDetector(appDir, buildConfigDir, orderPath, platformDir string, logger log.LoggerHandlerWithLevel) (*Detector, error)
type DirStore ¶ added in v0.15.0
type DirStore interface { Lookup(kind, id, version string) (buildpack.Descriptor, error) LookupBp(id, version string) (*buildpack.BpDescriptor, error) LookupExt(id, version string) (*buildpack.ExtDescriptor, error) }
type DockerfileApplier ¶ added in v0.15.0
type ExportOptions ¶ added in v0.7.0
type ExportOptions struct { LayersDir string AppDir string WorkingImage imgutil.Image RunImageRef string OrigMetadata platform.LayersMetadata AdditionalNames []string LauncherConfig LauncherConfig Stack platform.StackMetadata Project platform.ProjectMetadata DefaultProcessType string }
type Exporter ¶
type Exporter struct { Buildpacks []buildpack.GroupElement LayerFactory LayerFactory Logger log.Logger PlatformAPI *api.Version }
func (*Exporter) Export ¶
func (e *Exporter) Export(opts ExportOptions) (platform.ExportReport, error)
type Extender ¶ added in v0.15.0
type Extender struct { AppDir string GeneratedDir string GroupPath string ImageRef string LayersDir string PlatformDir string CacheTTL time.Duration DockerfileApplier DockerfileApplier Extensions []buildpack.GroupElement Logger log.Logger }
func (*Extender) ExtendBuild ¶ added in v0.15.0
type ExtenderFactory ¶ added in v0.15.0
type ExtenderFactory struct {
// contains filtered or unexported fields
}
func NewExtenderFactory ¶ added in v0.15.0
func NewExtenderFactory(apiVerifier BuildpackAPIVerifier, configHandler ConfigHandler) *ExtenderFactory
func (*ExtenderFactory) NewExtender ¶ added in v0.15.0
type GenerateResult ¶ added in v0.15.0
type Generator ¶ added in v0.15.0
type Generator struct { AppDir string BuildConfigDir string GeneratedDir string // e.g., <layers>/generated PlatformDir string DirStore DirStore Executor buildpack.GenerateExecutor Extensions []buildpack.GroupElement Logger log.Logger Out, Err io.Writer Plan platform.BuildPlan }
func (*Generator) Generate ¶ added in v0.15.0
func (g *Generator) Generate() (GenerateResult, error)
type GeneratorFactory ¶ added in v0.15.0
type GeneratorFactory struct {
// contains filtered or unexported fields
}
func NewGeneratorFactory ¶ added in v0.15.0
func NewGeneratorFactory( apiVerifier BuildpackAPIVerifier, dirStore DirStore, ) *GeneratorFactory
func (*GeneratorFactory) NewGenerator ¶ added in v0.15.0
type ImageHandler ¶ added in v0.14.1
type LauncherConfig ¶
type LauncherConfig struct { Path string SBOMDir string Metadata platform.LauncherMetadata }
type LayerFactory ¶ added in v0.8.1
type MultiError ¶
type MultiError struct {
Errors []error
}
func (*MultiError) Error ¶
func (me *MultiError) Error() string
type RebaseReport ¶ added in v0.9.0
type RebaseReport struct {
Image platform.ImageReport `toml:"image"`
}
type RegistryHandler ¶ added in v0.14.1
type Restorer ¶
type Restorer struct { LayersDir string Logger log.Logger Buildpacks []buildpack.GroupElement LayerMetadataRestorer layer.MetadataRestorer // Platform API >= 0.7 LayersMetadata platform.LayersMetadata // Platform API >= 0.7 PlatformAPI *api.Version SBOMRestorer layer.SBOMRestorer }
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
testmock
Package testmock is a generated GoMock package.
|
Package testmock is a generated GoMock package. |
internal
|
|
testmock
Package testmock is a generated GoMock package.
|
Package testmock is a generated GoMock package. |
Package testmock is a generated GoMock package.
|
Package testmock is a generated GoMock package. |
tools
|
|
Click to show internal directories.
Click to hide internal directories.