Documentation
¶
Index ¶
Constants ¶
View Source
const ( ErrFailedToGetApps = "failed to get apps" ErrFailedToGetAppStorage = "failed to get app storage" ErrFailedToGetComponentVersions = "failed to get component versions" ErrFailedToGetLogs = "failed to get logs" DefaultAutoUpdateAppsSchedule = "0 3 * * *" )
View Source
const ( ErrFailedToPopulateAppStore = "failed to populate app store" DefaultAppStoreURL = "https://apps.home-cloud.io/index.yaml" DefaultAppStoreRawChartURL = "https://raw.githubusercontent.com/home-cloud-io/store" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Controller ¶
type Controller interface {
// Install will install the requested app.
Install(ctx context.Context, logger chassis.Logger, request *v1.InstallAppRequest) error
// Delete will delete the requested app.
Delete(ctx context.Context, logger chassis.Logger, request *v1.DeleteAppRequest) error
// Update will update the requested app.
//
// NOTE: An empty value on the spec will be applied as empty and will NOT
// default to the existing value.
Update(ctx context.Context, logger chassis.Logger, request *v1.UpdateAppRequest) error
// Store returns all apps currently available in the store.
Store(ctx context.Context, logger chassis.Logger) ([]*v1.App, error)
// UpdateAll will update all apps to the latest available version in the store.
UpdateAll(ctx context.Context, logger chassis.Logger) error
// PrettyHealthcheck will retrieve the health of all installed apps and include the displayName
// from the chart, icon, and readme/description.
PrettyHealthcheck(ctx context.Context, logger chassis.Logger) ([]*v1.AppHealth, error)
// AutoUpdate will check for and install app updates on a schedule.
AutoUpdate(ctx context.Context, logger chassis.Logger)
// GetAppStorage will retrieve the app storage volumes for all installed apps.
GetAppStorage(ctx context.Context, logger chassis.Logger) ([]*v1.AppStorage, error)
}
func NewController ¶
func NewController(kclient k8sclient.Apps) Controller
type HelmIndex ¶
HelmIndex represents the exact shape of a Helm repository index file: e.g. https://apps.home-cloud.io/index.yaml
NOTE: This is a local type instead of a protobuf because protobufs cannot represent a map with an array/slice as the value but that is needed to unmarshal the yaml from the Helm index.
Click to show internal directories.
Click to hide internal directories.