mirror of
https://github.com/containrrr/watchtower.git
synced 2026-01-12 12:08:50 +01:00
Only update the selected containers
This commit is contained in:
parent
ee9475bcda
commit
cdde01709c
4 changed files with 63 additions and 52 deletions
|
|
@ -190,7 +190,10 @@ func Run(c *cobra.Command, names []string) {
|
|||
httpAPI := api.New(apiToken)
|
||||
|
||||
if enableUpdateAPI {
|
||||
updateHandler := update.New(func(images []string) { runUpdatesWithNotifications(filters.FilterByImage(images, filter)) }, updateLock)
|
||||
updateHandler := update.New(
|
||||
func(images []string) { runUpdatesWithNotifications(filters.FilterByImage(images, filter)) },
|
||||
func(containers []string) { runUpdatesWithNotifications(filters.FilterByNames(containers, filter)) },
|
||||
updateLock)
|
||||
httpAPI.RegisterFunc(updateHandler.Path, updateHandler.Handle)
|
||||
// If polling isn't enabled the scheduler is never started and
|
||||
// we need to trigger the startup messages manually.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue