WIP: feat: use compose-go
Some checks failed
continuous-integration/drone/push Build is failing

See #492
This commit is contained in:
2026-04-01 19:32:23 +02:00
parent aae20f07cc
commit 5eea459bde
231 changed files with 44914 additions and 1478 deletions

View File

@ -12,6 +12,7 @@ import (
stdlibErr "errors"
tea "github.com/charmbracelet/bubbletea"
composeGoTypes "github.com/compose-spec/compose-go/v2/types"
"coopcloud.tech/abra/pkg/config"
"coopcloud.tech/abra/pkg/i18n"
@ -20,7 +21,6 @@ import (
"coopcloud.tech/abra/pkg/upstream/convert"
"github.com/docker/cli/cli/command"
"github.com/docker/cli/cli/command/stack/formatter"
composetypes "github.com/docker/cli/cli/compose/types"
"github.com/docker/docker/api/types"
"github.com/docker/docker/api/types/container"
"github.com/docker/docker/api/types/filters"
@ -197,7 +197,7 @@ func pruneServices(ctx context.Context, cl *dockerClient.Client, namespace conve
func RunDeploy(
cl *dockerClient.Client,
opts Deploy,
cfg *composetypes.Config,
cfg *composeGoTypes.Project,
appName string,
serverName string,
dontWait bool,
@ -246,7 +246,7 @@ func deployCompose(
ctx context.Context,
cl *dockerClient.Client,
opts Deploy,
config *composetypes.Config,
config *composeGoTypes.Project,
appName string,
serverName string,
dontWait bool,
@ -325,7 +325,7 @@ func deployCompose(
return nil
}
func getServicesDeclaredNetworks(serviceConfigs []composetypes.ServiceConfig) map[string]struct{} {
func getServicesDeclaredNetworks(serviceConfigs map[string]composeGoTypes.ServiceConfig) map[string]struct{} {
serviceNetworks := map[string]struct{}{}
for _, serviceConfig := range serviceConfigs {
if len(serviceConfig.Networks) == 0 {