From 5a77ff4e55a52052e906af5ab27e903b3001877b Mon Sep 17 00:00:00 2001 From: Moritz Date: Tue, 31 Jan 2023 16:05:46 +0100 Subject: [PATCH] resolve PR: include the service info in the log message --- pkg/config/app.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pkg/config/app.go b/pkg/config/app.go index f7d338f1..64de339d 100644 --- a/pkg/config/app.go +++ b/pkg/config/app.go @@ -478,11 +478,12 @@ func SetRecipeLabel(compose *composetypes.Config, stackName string, recipe strin } } -// add a label to signal that a deploy is a chaos deploy +// SetChaosLabel adds the label 'coop-cloud.${STACK_NAME}.chaos=true/false' to the app container +// to signal if the app is deployed in chaos mode func SetChaosLabel(compose *composetypes.Config, stackName string, chaos bool) { for _, service := range compose.Services { if service.Name == "app" { - logrus.Debugf("set chaos label to %s", chaos) + logrus.Debugf("set label 'coop-cloud.%s.chaos' to %s for %s", stackName, chaos, stackName) labelKey := fmt.Sprintf("coop-cloud.%s.chaos", stackName) service.Deploy.Labels[labelKey] = strconv.FormatBool(chaos) }