From e86432e13bbb165ceefe0e8b95def3ea4e5aa1ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20H=C3=BCske?= Date: Sun, 18 Feb 2024 12:49:44 +0100 Subject: [PATCH] Switch to go --- main.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/main.go b/main.go index f366226..f162914 100644 --- a/main.go +++ b/main.go @@ -7,7 +7,6 @@ import ( "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/filters" - "github.com/docker/docker/api/types/events" "github.com/docker/docker/client" ) @@ -69,7 +68,7 @@ func handleEvent(ctx context.Context, cli *client.Client, event types.EventsMess } func restartContainer(ctx context.Context, cli *client.Client, containerName string) { - err := cli.ContainerRestart(ctx, containerName, &container.StopOptions{}) + err := cli.ContainerRestart(ctx, containerName, nil) if err != nil { fmt.Printf("Error restarting container %s: %v\n", containerName, err) } else {