mirror of
https://github.com/portainer/portainer.git
synced 2025-08-05 05:45:22 +02:00
fix(registry): remove k8s registry secrets when registries are removed [EE-5768] (#10369)
This commit is contained in:
parent
96ead31a8d
commit
860890046d
10 changed files with 206 additions and 47 deletions
|
@ -35,7 +35,7 @@ func RefreshEcrSecret(cli portainer.KubeClient, endpoint *portainer.Endpoint, da
|
|||
return
|
||||
}
|
||||
|
||||
err = cli.DeleteRegistrySecret(®istry, namespace)
|
||||
err = cli.DeleteRegistrySecret(registry.ID, namespace)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
|
|
@ -312,7 +312,10 @@ func updateEndpointStatus(tx dataservices.DataStoreTx, endpoint *portainer.Endpo
|
|||
|
||||
// Run the pending actions
|
||||
if latestEndpointReference.Status == portainer.EndpointStatusUp {
|
||||
pendingActionsService.Execute(endpoint.ID)
|
||||
err = pendingActionsService.Execute(endpoint.ID)
|
||||
if err != nil {
|
||||
log.Error().Err(err).Msg("background schedule error (environment snapshot), unable to execute pending actions")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue