Documentation
¶
Index ¶
- func RegisterVersion(api huma.API, versionService *VersionService)
- type GetAppVersionInput
- type GetAppVersionOutput
- type GetVersionInput
- type GetVersionOutput
- type VersionHandler
- type VersionService
- func (s *VersionService) GetAppVersionInfo(ctx context.Context) *types.VersionInfo
- func (s *VersionService) GetLatestVersion(ctx context.Context) (string, error)
- func (s *VersionService) GetVersionInformation(ctx context.Context, currentVersion string) (*types.VersionCheck, error)
- func (s *VersionService) IsNewer(latest, current string) bool
- func (s *VersionService) ReleaseURL(localVersion string) string
- func (s *VersionService) RunStreamProducer(ctx context.Context, events chan<- types.VersionStreamEvent)
- type VersionServiceParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterVersion ¶
func RegisterVersion(api huma.API, versionService *VersionService)
Types ¶
type GetAppVersionInput ¶
type GetAppVersionInput struct{}
type GetAppVersionOutput ¶
type GetAppVersionOutput struct {
Body types.VersionInfo
}
type GetVersionInput ¶
type GetVersionInput struct {
Current string `query:"current" doc:"Current version to compare against"`
}
type GetVersionOutput ¶
type GetVersionOutput struct {
Body types.VersionCheck
}
type VersionHandler ¶
type VersionHandler struct {
// contains filtered or unexported fields
}
func (*VersionHandler) GetAppVersion ¶
func (h *VersionHandler) GetAppVersion(ctx context.Context, _ *GetAppVersionInput) (*GetAppVersionOutput, error)
func (*VersionHandler) GetVersion ¶
func (h *VersionHandler) GetVersion(ctx context.Context, input *GetVersionInput) (*GetVersionOutput, error)
type VersionService ¶
type VersionService struct {
// contains filtered or unexported fields
}
func NewVersionService ¶
func NewVersionService(p VersionServiceParams) *VersionService
func (*VersionService) GetAppVersionInfo ¶
func (s *VersionService) GetAppVersionInfo(ctx context.Context) *types.VersionInfo
func (*VersionService) GetLatestVersion ¶
func (s *VersionService) GetLatestVersion(ctx context.Context) (string, error)
func (*VersionService) GetVersionInformation ¶
func (s *VersionService) GetVersionInformation(ctx context.Context, currentVersion string) (*types.VersionCheck, error)
func (*VersionService) IsNewer ¶
func (s *VersionService) IsNewer(latest, current string) bool
func (*VersionService) ReleaseURL ¶
func (s *VersionService) ReleaseURL(localVersion string) string
func (*VersionService) RunStreamProducer ¶
func (s *VersionService) RunStreamProducer(ctx context.Context, events chan<- types.VersionStreamEvent)
type VersionServiceParams ¶
type VersionServiceParams struct {
HTTPClient *http.Client
ContainerRegistryService *registry.ContainerRegistryService
DockerService *docker.DockerClientService
EventService *event.EventService
ImageUpdateService *imageupdate.ImageUpdateService
SettingsService *settings.SettingsService
AppVersion string
Revision string
}
Click to show internal directories.
Click to hide internal directories.