Documentation ¶
Index ¶
- func AutomaticUpgrade(ctx context.Context, localEnv, updateEnv *localenv.LocalEnvironment) (err error)
- func InitOperationPlan(ctx context.Context, localEnv, updateEnv *localenv.LocalEnvironment, ...) (*storage.OperationPlan, error)
- func New(ctx context.Context, config Config) (*update.Updater, error)
- func NewOperationPlan(config PlanConfig) (*storage.OperationPlan, error)
- func NumParallel() int
- func ShutdownClusterAgents(ctx context.Context, remote rpc.AgentRepository) error
- type Config
- type PlanConfig
- type UserConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AutomaticUpgrade ¶
func AutomaticUpgrade(ctx context.Context, localEnv, updateEnv *localenv.LocalEnvironment) (err error)
AutomaticUpgrade starts automatic upgrade process
func InitOperationPlan ¶
func InitOperationPlan( ctx context.Context, localEnv, updateEnv *localenv.LocalEnvironment, clusterEnv *localenv.ClusterEnvironment, opKey ops.SiteOperationKey, leader *storage.Server, userConfig UserConfig, ) (*storage.OperationPlan, error)
InitOperationPlan will initialize operation plan for an operation
func NewOperationPlan ¶
func NewOperationPlan(config PlanConfig) (*storage.OperationPlan, error)
NewOperationPlan generates a new plan for the provided operation
func NumParallel ¶
func NumParallel() int
NumParallel sets number of parallel phases we should run that scales based on the number of the CPU cores on the node generating the plan
func ShutdownClusterAgents ¶
func ShutdownClusterAgents(ctx context.Context, remote rpc.AgentRepository) error
ShutdownClusterAgents submits a shutdown request to all agents
Types ¶
type Config ¶
type Config struct { update.Config // HostLocalBackend is the host-local backend that stores bootstrap configuration // like DNS, logins etc. HostLocalBackend storage.LocalBackend // Packages is the local package service Packages pack.PackageService // ClusterPackages is the package service that talks to cluster API ClusterPackages pack.PackageService // HostLocalPackages is the host-local package service that contains package // metadata used for updates HostLocalPackages update.LocalPackageService // Apps is the cluster apps service Apps app.Applications // Client is the cluster Kubernetes client Client *kubernetes.Clientset // Users is the cluster identity service Users users.Identity // Spec is used to retrieve a phase executor, allows // plugging different phase executors during tests Spec fsm.FSMSpecFunc }
Config is the FSM configuration
type PlanConfig ¶
type PlanConfig struct { Backend storage.Backend Packages pack.PackageService Apps app.Applications DNSConfig storage.DNSConfig Operator ops.Operator Operation *storage.SiteOperation Client *kubernetes.Clientset Leader *storage.Server UserConfig UserConfig }
PlanConfig defines the configuration for creating a new operation plan
type UserConfig ¶
UserConfig holds configuration parameters provided by the user triggering the update operation.
Click to show internal directories.
Click to hide internal directories.