19 lines
445 B
Go
19 lines
445 B
Go
package node
|
|
|
|
import (
|
|
"context"
|
|
|
|
"k8s.io/klog/v2"
|
|
system "undecided.project/monok8s/pkg/system"
|
|
)
|
|
|
|
// Cluster is fine without uboot commands, just no OSUpgrade agent
|
|
func StartControlAgent(ctx context.Context, n *NodeContext) error {
|
|
err := ConfigureUBootCommands(ctx, n)
|
|
if err == nil {
|
|
return system.EnsureServiceRunning(ctx, n.SystemRunner, "control-agent")
|
|
}
|
|
klog.Warningf("not starting agent due to uboot: %v", err)
|
|
return nil
|
|
}
|