Documentation ¶
Index ¶
- Variables
- type Archiver
- type DependencyManager
- type Index
- func (i *Index) Add(md *chart.Metadata, urls []string, createdAt time.Time) bool
- func (i *Index) CompressedWriteTo(w io.Writer) (n int64, err error)
- func (i *Index) Count() (int, int)
- func (i *Index) Get(name, version string) (*repo.ChartVersion, error)
- func (i *Index) Unmarshal(data []byte) error
- func (i *Index) WriteTo(w io.Writer) (n int64, err error)
- type IndexDirectories
- type IndexDirectory
- type IndexManager
- type Repository
Constants ¶
This section is empty.
Variables ¶
var ( // ErrInvalidPackageName is raised when a chart package cannot be found ErrInvalidPackageName = errors.New("invalid package name") // ErrRepositoryNotFound is raised when the helm repository referenced in a package link cannot be found ErrRepositoryNotFound = errors.New("repository not found") )
var ( // ErrIndexNotFound is raised when the named index does not exist ErrIndexNotFound = errors.New("index not found") )
Functions ¶
This section is empty.
Types ¶
type DependencyManager ¶
type DependencyManager struct {
// contains filtered or unexported fields
}
DependencyManager handles the downloading of chart dependencies. A chart dependency is a reference to a versioned chart within a remote repository.
To download a chart, first its repository index is downloaded and then searched to find the chart dependency URLs.
func NewDependencyManager ¶
func NewDependencyManager(logger log.Logger, indexManager *IndexManager) *DependencyManager
NewDependencyManager returns a new dependency manager.
func (*DependencyManager) AddRepository ¶
func (dm *DependencyManager) AddRepository(repo Repository)
AddRepository adds a local repository for resolving local dependencies.
func (*DependencyManager) Download ¶
func (dm *DependencyManager) Download(dependencies []*chartutil.Dependency) (map[string][]byte, error)
Download fetches multiple dependencies concurrently and returns a map of the (chart name, archive data).
func (*DependencyManager) IndexManager ¶
func (dm *DependencyManager) IndexManager() *IndexManager
IndexManager returns the index manager.
type Index ¶
type Index struct {
// contains filtered or unexported fields
}
Index handles the indexing of charts.
func (*Index) CompressedWriteTo ¶
CompressedWriteTo is the same as WriteTo but with gzip compressed data.
func (*Index) Get ¶
func (i *Index) Get(name, version string) (*repo.ChartVersion, error)
Get returns the metadata of a specific chart version.
type IndexDirectories ¶
type IndexDirectories []IndexDirectory
IndexDirectories is a slice of IndexDirectory
func (IndexDirectories) Match ¶
func (id IndexDirectories) Match(path string) bool
Match checks whether a path matches any of the index directories
type IndexDirectory ¶
IndexDirectory maps a directory to a named index
type IndexManager ¶
type IndexManager struct {
// contains filtered or unexported fields
}
IndexManager manages multiple indexes
func NewIndexManager ¶
func NewIndexManager() *IndexManager
NewIndexManager returns a new IndexManager
func (*IndexManager) Create ¶
func (m *IndexManager) Create(name string) *Index
Create creates a new named index
func (*IndexManager) Get ¶
func (m *IndexManager) Get(name string) (*Index, error)
Get returns an instance by name
func (*IndexManager) Names ¶
func (m *IndexManager) Names() []string
Names returns all index names assigned to the manager
type Repository ¶
type Repository interface { URL() string Name() string ChartPackage(string) (Archiver, error) Update() error }
Repository represents a generic repository.
func NewGitBackedRepository ¶
func NewGitBackedRepository(logger log.Logger, dependencyManager *DependencyManager, name, url string, directories []IndexDirectory) Repository
NewGitBackedRepository returns a new git-backed based repository.