From 194571f75658d3e190786f3186692670d132155c Mon Sep 17 00:00:00 2001 From: Zaraki Date: Tue, 26 Nov 2019 12:02:17 +0100 Subject: [PATCH] fix: pw compose down by abridged hash fixed (needed to check one more char) chore: pw compose down by challenge name+version (flavor) separator changed from ':' to '@' to match pw compose ps format --- go/pkg/pwcompose/compose.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/go/pkg/pwcompose/compose.go b/go/pkg/pwcompose/compose.go index fc351e1a7..718c83799 100644 --- a/go/pkg/pwcompose/compose.go +++ b/go/pkg/pwcompose/compose.go @@ -247,7 +247,7 @@ func Down( for _, id := range ids { for _, flavor := range pwInfo.RunningFlavors { - if id == flavor.Name || id == flavor.Name+":"+flavor.Version { + if id == flavor.Name || id == flavor.Name+"@"+flavor.Version { for _, instance := range flavor.Instances { containersToRemove = append(containersToRemove, instance.ID) if removeImages == true { @@ -257,7 +257,7 @@ func Down( } } for _, container := range pwInfo.RunningInstances { - if id == container.ID || id == container.ID[0:6] { + if id == container.ID || id == container.ID[0:7] { containersToRemove = append(containersToRemove, container.ID) if removeImages == true { imagesToRemove = append(imagesToRemove, container.ImageID)