From 2eeed8481d43753d23bdbdcf5659b229a61fb71b Mon Sep 17 00:00:00 2001 From: Ulysses Souza Date: Wed, 2 Feb 2022 02:30:02 +0100 Subject: [PATCH] Fix pause/unpause by only applying to running containers Signed-off-by: Ulysses Souza --- pkg/compose/pause.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/compose/pause.go b/pkg/compose/pause.go index 041dc08cb..ac94760e4 100644 --- a/pkg/compose/pause.go +++ b/pkg/compose/pause.go @@ -33,7 +33,7 @@ func (s *composeService) Pause(ctx context.Context, project string, options api. } func (s *composeService) pause(ctx context.Context, project string, options api.PauseOptions) error { - containers, err := s.getContainers(ctx, project, oneOffExclude, true, options.Services...) + containers, err := s.getContainers(ctx, project, oneOffExclude, false, options.Services...) if err != nil { return err } @@ -61,7 +61,7 @@ func (s *composeService) UnPause(ctx context.Context, project string, options ap } func (s *composeService) unPause(ctx context.Context, project string, options api.PauseOptions) error { - containers, err := s.getContainers(ctx, project, oneOffExclude, true, options.Services...) + containers, err := s.getContainers(ctx, project, oneOffExclude, false, options.Services...) if err != nil { return err }