Documentation
¶
Index ¶
- type Config
- type IndexGC
- type Indexer
- type IndexerCommand
- type Manifest
- type ManifestManager
- func (m *ManifestManager) Delete(ctx context.Context, manifest Manifest) error
- func (m *ManifestManager) FindExpiredManifests(ctx context.Context) ([]Manifest, error)
- func (m *ManifestManager) Get(ctx context.Context, ts uint64) (Manifest, error)
- func (m *ManifestManager) GetAll(ctx context.Context) ([]Manifest, error)
- func (m *ManifestManager) GetLatest(ctx context.Context) (Manifest, error)
- func (m *ManifestManager) Update(ctx context.Context, manifest Manifest) error
- type Notify
- type ObjectStorageIndexManager
- func (s *ObjectStorageIndexManager) Add(ctx context.Context, name string, files []string) (string, uint64, error)
- func (s *ObjectStorageIndexManager) CleanUploadedFiles(ctx context.Context) error
- func (s *ObjectStorageIndexManager) Delete(ctx context.Context, manifests []Manifest) error
- func (s *ObjectStorageIndexManager) Download(ctx context.Context, indexDir string, manifest Manifest) error
- func (s *ObjectStorageIndexManager) ExecutionKey() uint64
- type Repository
- type RepositoryIndex
- type RepositoryLister
- type RepositoryListerOpt
- type RepositorySchema
- type Rule
- type StorageClient
- type Subscription
- type UpdaterCommand
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
RefreshSchedule string `yaml:"refresh_schedule,omitempty"`
Rules []*Rule `yaml:"rules,omitempty"`
}
func ReadConfigFile ¶
type IndexGC ¶
type IndexGC struct {
// contains filtered or unexported fields
}
func NewIndexGC ¶
func NewIndexGC(s StorageClient, bucket string) *IndexGC
type Indexer ¶
type Indexer struct {
Indexes []*RepositoryIndex
// contains filtered or unexported fields
}
func NewIndexer ¶
type IndexerCommand ¶
type IndexerCommand struct {
ConfigFile string
WorkDir string
RunScheduler bool
InitRun bool
WithoutFetch bool
DisableCleanup bool
Parallelism int
HTTPAddr string
URLReplaceRegexp []string
CABundleFile string
Bucket string
MinIOEndpoint string
MinIORegion string
MinIOName string
MinIONamespace string
MinIOPort int
MinIOAccessKey string
MinIOSecretAccessKey string
MinIOSecretAccessKeyFile string
S3Endpoint string
S3Region string
S3AccessKey string
S3SecretAccessKey string
S3CACertFile string
S3PartSize uint64
DisableObjectStorageCleanup bool
NATSURL string
NATSStreamName string
NATSSubject string
Dev bool
// contains filtered or unexported fields
}
func NewIndexerCommand ¶
func NewIndexerCommand() *IndexerCommand
func (*IndexerCommand) Flags ¶
func (r *IndexerCommand) Flags(fs *cli.FlagSet)
func (*IndexerCommand) Init ¶
func (r *IndexerCommand) Init() error
func (*IndexerCommand) Run ¶
func (r *IndexerCommand) Run() error
func (*IndexerCommand) ValidateFlags ¶
func (r *IndexerCommand) ValidateFlags() error
type Manifest ¶
type ManifestManager ¶
type ManifestManager struct {
// contains filtered or unexported fields
}
func NewManifestManager ¶
func NewManifestManager(backend StorageClient) *ManifestManager
func (*ManifestManager) Delete ¶
func (m *ManifestManager) Delete(ctx context.Context, manifest Manifest) error
func (*ManifestManager) FindExpiredManifests ¶
func (m *ManifestManager) FindExpiredManifests(ctx context.Context) ([]Manifest, error)
func (*ManifestManager) GetAll ¶
func (m *ManifestManager) GetAll(ctx context.Context) ([]Manifest, error)
type Notify ¶
type Notify struct {
// contains filtered or unexported fields
}
func (*Notify) Subscribe ¶
func (n *Notify) Subscribe(manifestManager *ManifestManager) (*Subscription, error)
type ObjectStorageIndexManager ¶
type ObjectStorageIndexManager struct {
// contains filtered or unexported fields
}
func NewObjectStorageIndexManager ¶
func NewObjectStorageIndexManager(s StorageClient, bucket string) *ObjectStorageIndexManager
func (*ObjectStorageIndexManager) CleanUploadedFiles ¶
func (s *ObjectStorageIndexManager) CleanUploadedFiles(ctx context.Context) error
func (*ObjectStorageIndexManager) Delete ¶
func (s *ObjectStorageIndexManager) Delete(ctx context.Context, manifests []Manifest) error
func (*ObjectStorageIndexManager) ExecutionKey ¶
func (s *ObjectStorageIndexManager) ExecutionKey() uint64
type Repository ¶
type Repository struct {
Name string
URL string
DisableVendoring bool
Refs []plumbing.ReferenceName
CABundle []byte
// contains filtered or unexported fields
}
func NewRepository ¶
func NewRepository(name, url string, refs []plumbing.ReferenceName, disableVendoring bool, caBundle []byte) *Repository
type RepositoryIndex ¶
func NewRepositoryIndex ¶
func NewRepositoryIndex(name, indexDir string) (*RepositoryIndex, error)
type RepositoryLister ¶
type RepositoryLister struct {
// contains filtered or unexported fields
}
func NewRepositoryLister ¶
func (*RepositoryLister) ClearCache ¶
func (x *RepositoryLister) ClearCache()
func (*RepositoryLister) List ¶
func (x *RepositoryLister) List(ctx context.Context) []*Repository
type RepositoryListerOpt ¶
type RepositoryListerOpt func(lister *RepositoryLister) error
type RepositorySchema ¶
type Rule ¶
type Rule struct {
Owner string `yaml:"owner,omitempty"`
Name string `yaml:"name,omitempty"`
Query string `yaml:"query,omitempty"`
Branches []string `yaml:"branches,omitempty"`
Tags []string `yaml:"tags,omitempty"`
URLReplace string `yaml:"url_replace"`
DisableVendoring bool `yaml:"disable_vendoring"`
// contains filtered or unexported fields
}
type StorageClient ¶
type Subscription ¶
type Subscription struct {
// contains filtered or unexported fields
}
func (*Subscription) Close ¶
func (s *Subscription) Close()
type UpdaterCommand ¶
type UpdaterCommand struct {
IndexDir string
Subscribe bool
HTTPAddr string
Bucket string
MinIOEndpoint string
MinIORegion string
MinIOName string
MinIONamespace string
MinIOPort int
MinIOAccessKey string
MinIOSecretAccessKey string
MinIOSecretAccessKeyFile string
S3Endpoint string
S3Region string
S3AccessKey string
S3SecretAccessKey string
S3CACertFile string
NATSURL string
NATSStreamName string
NATSSubject string
Dev bool
// contains filtered or unexported fields
}
func NewUpdaterCommand ¶
func NewUpdaterCommand() *UpdaterCommand
func (*UpdaterCommand) Collect ¶
func (u *UpdaterCommand) Collect(ch chan<- prometheus.Metric)
func (*UpdaterCommand) Describe ¶
func (u *UpdaterCommand) Describe(desc chan<- *prometheus.Desc)
func (*UpdaterCommand) Flags ¶
func (u *UpdaterCommand) Flags(fs *pflag.FlagSet)
func (*UpdaterCommand) Run ¶
func (u *UpdaterCommand) Run() error
Click to show internal directories.
Click to hide internal directories.