From 44d2b29d0f95b01c5772b8065b7f706f844b6a5b Mon Sep 17 00:00:00 2001 From: aiordache Date: Wed, 21 Apr 2021 10:23:36 +0200 Subject: [PATCH] Remove service.Build and service.PullPolicy fields when generating the config hash Signed-off-by: aiordache --- utils/hash.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/utils/hash.go b/utils/hash.go index ee3dc4e21..2715f5b0d 100644 --- a/utils/hash.go +++ b/utils/hash.go @@ -26,6 +26,9 @@ import ( // ServiceHash compute configuration has for a service // TODO move this to compose-go func ServiceHash(o types.ServiceConfig) (string, error) { + // remove the Build config when generating the service hash + o.Build = nil + o.PullPolicy = "" bytes, err := json.Marshal(o) if err != nil { return "", err