Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CompleteBundle ¶
CompleteBundle aggregates a bundle with his chart(s)
func (*CompleteBundle) ID ¶
func (b *CompleteBundle) ID() internal.BundleID
ID returns the ID of the bundle
type CompleteBundleProvider ¶
type CompleteBundleProvider struct {
// contains filtered or unexported fields
}
CompleteBundleProvider provides CompleteBundles from a repository.
func NewProvider ¶
func NewProvider(repo repository, bundleLoader bundleLoader, log logrus.FieldLogger) *CompleteBundleProvider
NewProvider returns new instance of CompleteBundleProvider.
func (*CompleteBundleProvider) ProvideBundles ¶
func (l *CompleteBundleProvider) ProvideBundles() ([]CompleteBundle, error)
ProvideBundles returns a list of bundles with his charts as CompleteBundle instances. In case of bundle processing errors, the won't be stopped - next bundle is processed.
type DocsMeta ¶
type DocsMeta struct {
Docs []internal.BundleDocs `yaml:"docs"`
}
DocsMeta contains data about bundle's docs fetched from docs/meta.yaml file
type DocsProvider ¶
type DocsProvider struct {
// contains filtered or unexported fields
}
DocsProvider allows to maintain the bundles documentation
func NewDocsProvider ¶
func NewDocsProvider(dynamicClient client.Client) *DocsProvider
NewDocsProvider creates a new DocsProvider
func (*DocsProvider) EnsureClusterDocsTopic ¶
func (d *DocsProvider) EnsureClusterDocsTopic(bundle *internal.Bundle) error
EnsureClusterDocsTopic creates ClusterDocsTopic for a given bundle or updates it in case it already exists
func (*DocsProvider) EnsureClusterDocsTopicRemoved ¶
func (d *DocsProvider) EnsureClusterDocsTopicRemoved(id string) error
EnsureClusterDocsTopicRemoved removes ClusterDocsTopic for a given bundle
type FormMeta ¶
type FormMeta struct { ID string `yaml:"id"` Name string `yaml:"name"` Version string `yaml:"version"` Description string `yaml:"description"` DisplayName string `yaml:"displayName"` Tags string `yaml:"tags"` ProviderDisplayName string `yaml:"providerDisplayName"` LongDescription string `yaml:"longDescription"` DocumentationURL string `yaml:"documentationURL"` SupportURL string `yaml:"supportURL"` ImageURL string `yaml:"imageURL"` Bindable bool `yaml:"bindable"` ProvisionOnlyOnce bool `yaml:"provisionOnlyOnce"` Labels map[string]string `yaml:"labels"` Requires []string `yaml:"requires"` BindingsRetrievable bool `yaml:"bindingsRetrievable"` PlanUpdatable *bool `yaml:"planUpdatable"` }
FormMeta describes the metdata information about the bundle.
func (*FormMeta) MapLabelsToModel ¶
MapLabelsToModel maps the FormMeta.Labels to the model internal.Labels
func (*FormMeta) MapTagsToModel ¶
MapTagsToModel maps the FormMeta.Tags to the model internal.BundleTag slice
type HTTPRepository ¶
type HTTPRepository struct { IndexFile string BaseURL string Client interface { Do(req *http.Request) (*http.Response, error) } }
HTTPRepository represents remote bundle repository which is accessed via HTTP.
func NewHTTPRepository ¶
func NewHTTPRepository(cfg RepositoryConfig) *HTTPRepository
NewHTTPRepository creates new instance of HTTPRepository.
func (*HTTPRepository) BundleReader ¶
func (p *HTTPRepository) BundleReader(name Name, version Version) (r io.ReadCloser, err error)
BundleReader calls repository for a specific bundle and returns means to read bundle content.
func (*HTTPRepository) IndexReader ¶
func (p *HTTPRepository) IndexReader() (r io.ReadCloser, err error)
IndexReader acquire repository index.
func (*HTTPRepository) URLForBundle ¶
func (p *HTTPRepository) URLForBundle(name Name, version Version) string
URLForBundle returns direct URL for getting the bundle
type Loader ¶
type Loader struct {
// contains filtered or unexported fields
}
Loader provides loading of bundles from repository and representing them as bundles and charts.
func NewLoader ¶
func NewLoader(tmpDir string, log logrus.FieldLogger) *Loader
NewLoader returns new instance of Loader.
type Provider ¶
type Provider interface {
ProvideBundles() ([]CompleteBundle, error)
}
Provider contains method which provides CompleteBundle items.
type RepositoryConfig ¶
type RepositoryConfig struct {
URL string `json:"URL" valid:"required"`
}
RepositoryConfig provides configuration for HTTP Repository.
func (RepositoryConfig) BaseURL ¶
func (cfg RepositoryConfig) BaseURL() string
BaseURL returns base url to bundles with trailing slash
func (RepositoryConfig) IndexFileName ¶
func (cfg RepositoryConfig) IndexFileName() string
IndexFileName returns name of yaml file with configuration (if not exist return default name)
type RepositoryController ¶
type RepositoryController struct {
// contains filtered or unexported fields
}
RepositoryController is responsible for updating repositories URL on configmap change
func NewRepositoryController ¶
func NewRepositoryController(bundleSyncer bundleSyncer, bundleloader bundleLoader, brokerSyncer brokerSyncer, brokerName string, cfgMapInformer cache.SharedIndexInformer, log logrus.FieldLogger, devMode bool) *RepositoryController
NewRepositoryController returns new RepositoryController instance.
func (*RepositoryController) Run ¶
func (c *RepositoryController) Run(stopCh <-chan struct{})
Run starts the controller for configmaps which provides bundles repos.
type Syncer ¶
type Syncer struct {
// contains filtered or unexported fields
}
Syncer is responsible for loading bundles from bundle providers and stores it into the storage.
func NewSyncer ¶
func NewSyncer(bundleOperations bundleOperations, chartOperations chartUpserter, docsTopicsService docsTopicsService, log logrus.FieldLogger) *Syncer
NewSyncer returns new Syncer instance.
func (*Syncer) AddProvider ¶
AddProvider registers new Provider which provides bundles from a repository and enrich bundles with the url.
func (*Syncer) CleanProviders ¶
func (s *Syncer) CleanProviders()
CleanProviders remove all providers from the map.
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
Code generated by mockery v1.0.0 Code generated by mockery v1.0.0 Code generated by mockery v1.0.0 Code generated by mockery v1.0.0
|
Code generated by mockery v1.0.0 Code generated by mockery v1.0.0 Code generated by mockery v1.0.0 Code generated by mockery v1.0.0 |