new package envfile and move GetComposeFiles to recipe package

This commit is contained in:
2024-07-06 16:13:17 +02:00
parent 37aff723c0
commit 0076b31253
15 changed files with 128 additions and 114 deletions

View File

@ -4,6 +4,7 @@ import (
"fmt"
"strconv"
"coopcloud.tech/abra/pkg/envfile"
composetypes "github.com/docker/cli/cli/compose/types"
"github.com/sirupsen/logrus"
)
@ -46,7 +47,7 @@ func SetChaosVersionLabel(compose *composetypes.Config, stackName string, chaosV
// SetUpdateLabel adds env ENABLE_AUTO_UPDATE as label to enable/disable the
// auto update process for this app. The default if this variable is not set is to disable
// the auto update process.
func SetUpdateLabel(compose *composetypes.Config, stackName string, appEnv AppEnv) {
func SetUpdateLabel(compose *composetypes.Config, stackName string, appEnv envfile.AppEnv) {
for _, service := range compose.Services {
if service.Name == "app" {
enable_auto_update, exists := appEnv["ENABLE_AUTO_UPDATE"]