service

package
v0.22.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 8, 2025 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BasicService added in v0.22.1

type BasicService struct {
	// contains filtered or unexported fields
}

BasicService provides common registry operations with standardized logging

func NewBasicService added in v0.22.1

func NewBasicService(name string, client pkg.RegistryClient, logger *log.Logger) *BasicService

NewBasicService creates a new basic service

func (*BasicService) CheckImageExists added in v0.22.1

func (s *BasicService) CheckImageExists(ctx context.Context, tag string) error

func (*BasicService) GetDigest added in v0.22.1

func (s *BasicService) GetDigest(ctx context.Context, tag string) (*v1.Hash, error)

GetDigest retrieves a digest from the registry

func (*BasicService) GetImage added in v0.22.1

func (s *BasicService) GetImage(ctx context.Context, tag string, opts ...pkg.ImageGetOption) (pkg.RegistryImage, error)

GetImage retrieves an image from the registry

func (*BasicService) ListTags added in v0.22.1

func (s *BasicService) ListTags(ctx context.Context) ([]string, error)

type DeckhouseReleaseMetadata added in v0.22.1

type DeckhouseReleaseMetadata struct {
	Version string
	Suspend bool
}

type DeckhouseReleaseService added in v0.22.1

type DeckhouseReleaseService struct {
	*BasicService
}

func NewDeckhouseReleaseService added in v0.22.1

func NewDeckhouseReleaseService(basicService *BasicService) *DeckhouseReleaseService

func (*DeckhouseReleaseService) GetMetadata added in v0.22.1

type DeckhouseService

type DeckhouseService struct {
	*BasicService
	// contains filtered or unexported fields
}

DeckhouseService provides high-level operations for Deckhouse platform management

func NewDeckhouseService

func NewDeckhouseService(client pkg.RegistryClient, logger *log.Logger) *DeckhouseService

NewDeckhouseService creates a new deckhouse service

func (*DeckhouseService) GetRoot added in v0.22.1

func (s *DeckhouseService) GetRoot() string

GetRoot gets path of the registry root

func (*DeckhouseService) Installer added in v0.22.1

func (s *DeckhouseService) Installer() *BasicService

func (*DeckhouseService) ReleaseChannels added in v0.22.1

func (s *DeckhouseService) ReleaseChannels() *DeckhouseReleaseService

func (*DeckhouseService) StandaloneInstaller added in v0.22.1

func (s *DeckhouseService) StandaloneInstaller() *BasicService

type EnvVarDTO

type EnvVarDTO struct {
	Name string `json:"name"`
}

EnvVarDTO represents an environment variable in JSON

type FlagDTO

type FlagDTO struct {
	Name string `json:"name"`
}

FlagDTO represents a flag in JSON

type KubernetesRequirementDTO

type KubernetesRequirementDTO struct {
	Constraint string `json:"constraint"`
}

KubernetesRequirementDTO represents Kubernetes requirement in JSON

type ModuleRequirementDTO

type ModuleRequirementDTO struct {
	Name       string `json:"name"`
	Constraint string `json:"constraint"`
}

ModuleRequirementDTO represents module requirement in JSON

type ModuleService

type ModuleService struct {
	// contains filtered or unexported fields
}

ModuleService provides high-level operations for module management

func NewModuleService

func NewModuleService(client pkg.RegistryClient, logger *log.Logger) *ModuleService

NewModuleService creates a new module service

func (*ModuleService) ExtractModule

func (s *ModuleService) ExtractModule(ctx context.Context, moduleName, tag, destination string) error

ExtractModule downloads the module image and extracts it to the specified location

func (*ModuleService) GetModuleInfo

func (s *ModuleService) GetModuleInfo(ctx context.Context, moduleName, tag string) (interface{}, error)

GetModuleInfo gets information about a specific module

func (*ModuleService) ListModuleTags

func (s *ModuleService) ListModuleTags(ctx context.Context, moduleName string) ([]string, error)

ListModuleTags lists all available tags for a specific module

func (*ModuleService) ListModules

func (s *ModuleService) ListModules(ctx context.Context) ([]string, error)

ListModules lists all available module names from the registry

type PluginContract

type PluginContract struct {
	Name         string          `json:"name"`
	Version      string          `json:"version"`
	Description  string          `json:"description"`
	Env          []EnvVarDTO     `json:"env,omitempty"`
	Flags        []FlagDTO       `json:"flags,omitempty"`
	Requirements RequirementsDTO `json:"requirements,omitempty"`
}

PluginContract represents the plugin contract metadata (DTO for JSON unmarshaling)

type PluginService

type PluginService struct {
	// contains filtered or unexported fields
}

PluginService provides high-level operations for plugin management

func NewPluginService

func NewPluginService(client pkg.RegistryClient, logger *log.Logger) *PluginService

NewPluginService creates a new plugin service

func (*PluginService) ExtractPlugin

func (s *PluginService) ExtractPlugin(ctx context.Context, pluginName, tag, destination string) error

ExtractPlugin downloads the plugin image and extracts it to the specified location

func (*PluginService) GetPluginContract

func (s *PluginService) GetPluginContract(ctx context.Context, pluginName, tag string) (*internal.Plugin, error)

GetPluginContract reads the plugin contract from image metadata annotation

func (*PluginService) ListPluginTags

func (s *PluginService) ListPluginTags(ctx context.Context, pluginName string) ([]string, error)

ListPluginTags lists all available tags for a specific plugin

func (*PluginService) ListPlugins

func (s *PluginService) ListPlugins(ctx context.Context) ([]string, error)

ListPlugins lists all available plugin names from the registry Note: This requires the registry to support the catalog API and grant access to it. If the registry doesn't allow catalog access, this will return an error.

type RequirementsDTO

type RequirementsDTO struct {
	Kubernetes KubernetesRequirementDTO `json:"kubernetes,omitempty"`
	Modules    []ModuleRequirementDTO   `json:"modules,omitempty"`
}

RequirementsDTO represents requirements in JSON

type Service

type Service struct {
	// contains filtered or unexported fields
}

Service provides high-level registry operations using a registry client

func NewService

func NewService(client pkg.RegistryClient, logger *log.Logger) *Service

NewService creates a new registry service with the given client and logger

func (*Service) DeckhouseService

func (s *Service) DeckhouseService() *DeckhouseService

DeckhouseService returns the deckhouse service

func (*Service) ModuleService

func (s *Service) ModuleService() *ModuleService

ModuleService returns the module service

func (*Service) PluginService

func (s *Service) PluginService() *PluginService

PluginService returns the plugin service

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL