mirror of
https://github.com/psviderski/uncloud.git
synced 2026-08-26 19:13:34 +00:00
add opptimistic sleep on corrosion service start to wait for schema initialisation
This commit is contained in:
@@ -64,11 +64,11 @@ func (nc *networkController) Run(ctx context.Context) error {
|
||||
|
||||
if nc.corroService.Running() {
|
||||
// Corrosion service was running before the WireGuard network was configured so we need to restart it.
|
||||
if err := nc.corroService.Restart(); err != nil {
|
||||
if err := nc.corroService.Restart(ctx); err != nil {
|
||||
return fmt.Errorf("restart corrosion service: %w", err)
|
||||
}
|
||||
} else {
|
||||
if err := nc.corroService.Start(); err != nil {
|
||||
if err := nc.corroService.Start(ctx); err != nil {
|
||||
return fmt.Errorf("start corrosion service: %w", err)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user