Documentation ¶
Index ¶
Constants ¶
View Source
const ( DependenciesKey = "io.cnab.dependencies" DependenciesSchema = "https://cnab.io/specs/v1/dependencies.schema.json" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Dependencies ¶
type Dependencies struct { // Requires is a list of bundles required by this bundle Requires map[string]Dependency `json:"requires,omitempty" mapstructure:"requires"` }
Dependencies describes the set of custom extension metadata associated with the dependencies spec https://github.com/deislabs/cnab-spec/blob/master/500-CNAB-dependencies.md
func ReadDependencies ¶
func ReadDependencies(bun *bundle.Bundle) (*Dependencies, error)
type Dependency ¶
type Dependency struct { // Bundle is the location of the bundle in a registry, for example REGISTRY/NAME:TAG Bundle string `json:"bundle" mapstructure:"bundle"` // Version is a set of allowed versions Version *DependencyVersion `json:"version,omitempty" mapstructure:"version"` }
Dependency describes a dependency on another bundle
type DependencyLock ¶
type DependencySolver ¶
type DependencySolver struct { }
func (*DependencySolver) ResolveDependencies ¶
func (s *DependencySolver) ResolveDependencies(bun *bundle.Bundle) ([]DependencyLock, error)
func (*DependencySolver) ResolveVersion ¶
func (s *DependencySolver) ResolveVersion(alias string, dep Dependency) (string, error)
type DependencyVersion ¶
type DependencyVersion struct { // Ranges of semantic versions, with or without the leading v prefix, allowed by the dependency Ranges []string `json:"ranges,omitempty" mapstructure:"ranges"` // AllowPrereleases specifies if prerelease versions can satisfy the dependency AllowPrereleases bool `json:"prereleases" mapstructure:"prereleases"` }
DependencyVersion is a set of allowed versions for a dependency
Click to show internal directories.
Click to hide internal directories.