Repository: docker/compose-cli
Pull request #912 (2020-11-16 11:53:45)

Compose api
**What I did**
* Add Compose gRPC service, and proxy for `compose up`, `compose down`, `compose ls`, `compose ps`
* tested with node-sdk compose sample

**Related issue**
https://github.com/docker/compose-cli/issues/890

<!-- optional tests
You can add a / mention to run tests executed by default only on main branch : 
* `test-aci` to run ACI E2E tests
* `test-ecs` to run ECS E2E tests
* `test-windows` to run tests & E2E tests on windows
-->

**(not mandatory) A picture of a cute animal, if possible in relation with what you did**
![](https://cdn.pixabay.com/photo/2017/06/22/12/19/tiger-2430625__340.jpg)


Patch:
diff --git a/cli/cmd/inspect.go b/cli/cmd/inspect.go
index 6ce9a0e2..2e964799 100644
--- a/cli/cmd/inspect.go
+++ b/cli/cmd/inspect.go
@@ -20,13 +20,10 @@ import (
 	"context"
 	"fmt"
 
-	"github.com/Azure/go-autorest/autorest/to"
-	"github.com/compose-spec/compose-go/types"
 	"github.com/pkg/errors"
 	"github.com/spf13/cobra"
 
 	"github.com/docker/compose-cli/api/client"
-	"github.com/docker/compose-cli/api/containers"
 	"github.com/docker/compose-cli/formatter"
 )
 
@@ -55,9 +52,7 @@ func runInspect(ctx context.Context, id string) error {
 		return err
 	}
 
-	view := getInspectView(container)
-
-	j, err := formatter.ToStandardJSON(view)
+	j, err := formatter.ToStandardJSON(container)
 	if err != nil {
 		return err
 	}
@@ -65,75 +60,3 @@ func runInspect(ctx context.Context, id string) error {
 
 	return nil
 }
-
-// ContainerInspectView inspect view
-type ContainerInspectView struct {
-	ID          string
-	Status      string
-	Image       string
-	Command     string                    `json:",omitempty"`
-	HostConfig  *containers.HostConfig    `json:",omitempty"`
-	Ports       []containers.Port         `json:",omitempty"`
-	Config      *containers.RuntimeConfig `json:",omitempty"`
-	Platform    string
-	Healthcheck *containerInspectHealthcheck `json:",omitempty"`
-}
-
-type containerInspectHealthcheck struct {
-	// Test is the command to be run to check the health of the container
-	Test []string `json:",omitempty"`
-	// Interval is the period in between the checks
-	Interval *types.Duration `json:",omitempty"`
-	// Retries is the number of attempts before declaring the container as healthy or unhealthy
-	Retries *int `json:",omitempty"`
-	// StartPeriod is the start delay before starting the checks
-	StartPeriod *types.Duration `json:",omitempty"`
-	// Timeout is the timeout in between checks
-	Timeout *types.Duration `json:",omitempty"`
-}
-
-func getInspectView(container containers.Container) ContainerInspectView {
-	var (
-		healthcheck *containerInspectHealthcheck
-		test        []string
-		retries     *int
-		ports       []containers.Port
-	)
-
-	if len(container.Ports) > 0 {
-		ports = container.Ports
-	}
-	if !container.Healthcheck.Disable && len(container.Healthcheck.Test) > 0 {
-		test = container.Healthcheck.Test
-		if container.Healthcheck.Retries != 0 {
-			retries = to.IntPtr(container.Healthcheck.Retries)
-		}
-		getDurationPtr := func(d types.Duration) *types.Duration {
-			if d == types.Duration(0) {
-				return nil
-			}
-			return &d
-		}
-
-		healthcheck = &containerInspectHealthcheck{
-			Test:        test,
-			Retries:     retries,
-			Interval:    getDurationPtr(container.Healthcheck.Interval),
-			StartPeriod: getDurationPtr(container.Healthcheck.StartPeriod),
-			Timeout:     getDurationPtr(container.Healthcheck.Timeout),
-		}
-	}
-
-	return ContainerInspectView{
-		ID:      container.ID,
-		Status:  container.Status,
-		Image:   container.Image,
-		Command: container.Command,
-
-		Config:      container.Config,
-		HostConfig:  container.HostConfig,
-		Ports:       ports,
-		Platform:    container.Platform,
-		Healthcheck: healthcheck,
-	}
-}
diff --git a/cli/cmd/serve.go b/cli/cmd/serve.go
index 84667ba8..d11e47a0 100644
--- a/cli/cmd/serve.go
+++ b/cli/cmd/serve.go
@@ -23,6 +23,7 @@ import (
 	"github.com/sirupsen/logrus"
 	"github.com/spf13/cobra"
 
+	composev1 "github.com/docker/compose-cli/protos/compose/v1"
 	containersv1 "github.com/docker/compose-cli/protos/containers/v1"
 	contextsv1 "github.com/docker/compose-cli/protos/contexts/v1"
 	streamsv1 "github.com/docker/compose-cli/protos/streams/v1"
@@ -64,6 +65,7 @@ func runServe(ctx context.Context, opts serveOpts) error {
 
 	p := proxy.New(ctx)
 
+	composev1.RegisterComposeServer(s, p)
 	containersv1.RegisterContainersServer(s, p)
 	contextsv1.RegisterContextsServer(s, p.ContextsProxy())
 	streamsv1.RegisterStreamingServer(s, p)
diff --git a/ecs/compatibility.go b/ecs/compatibility.go
index 8cc9b350..d79d3849 100644
--- a/ecs/compatibility.go
+++ b/ecs/compatibility.go
@@ -65,8 +65,6 @@ var compatibleComposeAttributes = []string{
 	"services.deploy.resources.reservations",
 	"services.deploy.resources.reservations.cpus",
 	"services.deploy.resources.reservations.memory",
-	"services.deploy.resources.reservations.devices",
-	"services.deploy.resources.reservations.devices.count",
 	"services.deploy.resources.reservations.generic_resources",
 	"services.deploy.resources.reservations.generic_resources.discrete_resource_spec",
 	"services.deploy.update_config",
@@ -159,11 +157,3 @@ func (c *fargateCompatibilityChecker) CheckUlimits(service *types.ServiceConfig)
 		}
 	}
 }
-
-func (c *fargateCompatibilityChecker) CheckDeployResourcesDevicesCapabilities(s string, r types.DeviceRequest) {
-	for _, cap := range r.Capabilities {
-		if cap != "gpu" {
-			c.Unsupported("services.deploy.resources.%s.devices.capabilities = %s", s, cap)
-		}
-	}
-}
diff --git a/ecs/context.go b/ecs/context.go
index 8c76635c..5d636ac3 100644
--- a/ecs/context.go
+++ b/ecs/context.go
@@ -199,15 +199,8 @@ func (h contextCreateAWSHelper) saveCredentials(profile string, accessKeyID stri
 		return err
 	}
 
-	credentials, err := ini.Load(file)
-	if err != nil {
-		if !os.IsNotExist(err) {
-			return err
-		}
-		credentials = ini.Empty()
-	}
-
-	section, err := credentials.NewSection(profile)
+	credIni := ini.Empty()
+	section, err := credIni.NewSection(profile)
 	if err != nil {
 		return err
 	}
@@ -219,7 +212,7 @@ func (h contextCreateAWSHelper) saveCredentials(profile string, accessKeyID stri
 	if err != nil {
 		return err
 	}
-	return credentials.SaveTo(file)
+	return credIni.SaveTo(file)
 }
 
 func (h contextCreateAWSHelper) saveRegion(profile, region string) error {
diff --git a/ecs/convert.go b/ecs/convert.go
index 3ba7e8bf..84e51e25 100644
--- a/ecs/convert.go
+++ b/ecs/convert.go
@@ -562,11 +562,6 @@ func gpuRequirements(s types.ServiceConfig) int64 {
 					return resource.DiscreteResourceSpec.Value
 				}
 			}
-			for _, device := range reservations.Devices {
-				if len(device.Capabilities) == 1 && device.Capabilities[0] == "gpu" {
-					return int64(device.Count)
-				}
-			}
 		}
 	}
 	return 0
diff --git a/go.mod b/go.mod
index 38a2efbe..1e05d104 100644
--- a/go.mod
+++ b/go.mod
@@ -22,7 +22,7 @@ require (
 	github.com/aws/aws-sdk-go v1.35.15
 	github.com/awslabs/goformation/v4 v4.15.3
 	github.com/buger/goterm v0.0.0-20200322175922-2f3e71b85129
-	github.com/compose-spec/compose-go v0.0.0-20201116112017-777513ca88e2
+	github.com/compose-spec/compose-go v0.0.0-20201104130931-5afecaa4cb35
 	github.com/containerd/console v1.0.1
 	github.com/containerd/containerd v1.3.5 // indirect
 	github.com/docker/cli v0.0.0-20200528204125-dd360c7c0de8
@@ -36,7 +36,7 @@ require (
 	github.com/gobwas/ws v1.0.4
 	github.com/golang/mock v1.4.4
 	github.com/golang/protobuf v1.4.3
-	github.com/google/go-cmp v0.5.3
+	github.com/google/go-cmp v0.5.2
 	github.com/google/uuid v1.1.2
 	github.com/gorilla/mux v1.7.4 // indirect
 	github.com/hashicorp/go-multierror v1.1.0
diff --git a/go.sum b/go.sum
index 6f081194..fb7ab35a 100644
--- a/go.sum
+++ b/go.sum
@@ -122,8 +122,8 @@ github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5P
 github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
 github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
 github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc=
-github.com/compose-spec/compose-go v0.0.0-20201116112017-777513ca88e2 h1:m6m0rnxmq3mPapGNAWqO6FLYg6GST7tJAAZqJ0pjadk=
-github.com/compose-spec/compose-go v0.0.0-20201116112017-777513ca88e2/go.mod h1:cZJ8y+zQzrYfN5XnEu/kMeDEP0V2D9ojF7Rb4nrneUc=
+github.com/compose-spec/compose-go v0.0.0-20201104130931-5afecaa4cb35 h1:HLxSiPmzCkBi3mGgxHQGBi3vxUuzT72Q9xjG49hkvSA=
+github.com/compose-spec/compose-go v0.0.0-20201104130931-5afecaa4cb35/go.mod h1:cBdHyUvAothdUpqXANCfTHU7cEqsXRvSiLxjhOTuwvc=
 github.com/containerd/cgroups v0.0.0-20190919134610-bf292b21730f h1:tSNMc+rJDfmYntojat8lljbt1mgKNpTxUZJsSzJ9Y1s=
 github.com/containerd/cgroups v0.0.0-20190919134610-bf292b21730f/go.mod h1:OApqhQ4XNSNC13gXIwDjhOQxjWa/NxkwZXJ1EvqT0ko=
 github.com/containerd/console v0.0.0-20180822173158-c12b1e7919c1/go.mod h1:Tj/on1eG8kiEhd0+fhSDzsPAFESxzBBvdyEgyryXffw=
@@ -256,8 +256,8 @@ github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/
 github.com/google/go-cmp v0.5.0 h1:/QaMHBdZ26BB3SSst0Iwl10Epc+xhTquomWX0oZEB6w=
 github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
 github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
-github.com/google/go-cmp v0.5.3 h1:x95R7cp+rSeeqAMI2knLtQ0DKlaBhv2NrtrOvafPHRo=
-github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.2 h1:X2ev0eStA3AbceY54o37/0PQ/UWqKEiiO2dKL5OPaFM=
+github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
 github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
 github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs=
 github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0=
diff --git a/protos/compose/v1/compose.pb.go b/protos/compose/v1/compose.pb.go
index 595d0fd9..9a16f4dd 100644
--- a/protos/compose/v1/compose.pb.go
+++ b/protos/compose/v1/compose.pb.go
@@ -111,6 +111,8 @@ type ComposeUpResponse struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
 	unknownFields protoimpl.UnknownFields
+
+	ProjectName string `protobuf:"bytes,1,opt,name=projectName,proto3" json:"projectName,omitempty"`
 }
 
 func (x *ComposeUpResponse) Reset() {
@@ -145,10 +147,21 @@ func (*ComposeUpResponse) Descriptor() ([]byte, []int) {
 	return file_protos_compose_v1_compose_proto_rawDescGZIP(), []int{1}
 }
 
+func (x *ComposeUpResponse) GetProjectName() string {
+	if x != nil {
+		return x.ProjectName
+	}
+	return ""
+}
+
 type ComposeDownRequest struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
 	unknownFields protoimpl.UnknownFields
+
+	ProjectName string   `protobuf:"bytes,1,opt,name=projectName,proto3" json:"projectName,omitempty"`
+	WorkDir     string   `protobuf:"bytes,2,opt,name=workDir,proto3" json:"workDir,omitempty"`
+	Files       []string `protobuf:"bytes,3,rep,name=files,proto3" json:"files,omitempty"`
 }
 
 func (x *ComposeDownRequest) Reset() {
@@ -183,10 +196,33 @@ func (*ComposeDownRequest) Descriptor() ([]byte, []int) {
 	return file_protos_compose_v1_compose_proto_rawDescGZIP(), []int{2}
 }
 
+func (x *ComposeDownRequest) GetProjectName() string {
+	if x != nil {
+		return x.ProjectName
+	}
+	return ""
+}
+
+func (x *ComposeDownRequest) GetWorkDir() string {
+	if x != nil {
+		return x.WorkDir
+	}
+	return ""
+}
+
+func (x *ComposeDownRequest) GetFiles() []string {
+	if x != nil {
+		return x.Files
+	}
+	return nil
+}
+
 type ComposeDownResponse struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
 	unknownFields protoimpl.UnknownFields
+
+	ProjectName string `protobuf:"bytes,1,opt,name=projectName,proto3" json:"projectName,omitempty"`
 }
 
 func (x *ComposeDownResponse) Reset() {
@@ -221,6 +257,367 @@ func (*ComposeDownResponse) Descriptor() ([]byte, []int) {
 	return file_protos_compose_v1_compose_proto_rawDescGZIP(), []int{3}
 }
 
+func (x *ComposeDownResponse) GetProjectName() string {
+	if x != nil {
+		return x.ProjectName
+	}
+	return ""
+}
+
+type ComposeListRequest struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	ProjectName string `protobuf:"bytes,1,opt,name=projectName,proto3" json:"projectName,omitempty"`
+}
+
+func (x *ComposeListRequest) Reset() {
+	*x = ComposeListRequest{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_protos_compose_v1_compose_proto_msgTypes[4]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *ComposeListRequest) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*ComposeListRequest) ProtoMessage() {}
+
+func (x *ComposeListRequest) ProtoReflect() protoreflect.Message {
+	mi := &file_protos_compose_v1_compose_proto_msgTypes[4]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use ComposeListRequest.ProtoReflect.Descriptor instead.
+func (*ComposeListRequest) Descriptor() ([]byte, []int) {
+	return file_protos_compose_v1_compose_proto_rawDescGZIP(), []int{4}
+}
+
+func (x *ComposeListRequest) GetProjectName() string {
+	if x != nil {
+		return x.ProjectName
+	}
+	return ""
+}
+
+type ComposeListResponse struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	Stacks []*Stack `protobuf:"bytes,1,rep,name=stacks,proto3" json:"stacks,omitempty"`
+}
+
+func (x *ComposeListResponse) Reset() {
+	*x = ComposeListResponse{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_protos_compose_v1_compose_proto_msgTypes[5]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *ComposeListResponse) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*ComposeListResponse) ProtoMessage() {}
+
+func (x *ComposeListResponse) ProtoReflect() protoreflect.Message {
+	mi := &file_protos_compose_v1_compose_proto_msgTypes[5]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use ComposeListResponse.ProtoReflect.Descriptor instead.
+func (*ComposeListResponse) Descriptor() ([]byte, []int) {
+	return file_protos_compose_v1_compose_proto_rawDescGZIP(), []int{5}
+}
+
+func (x *ComposeListResponse) GetStacks() []*Stack {
+	if x != nil {
+		return x.Stacks
+	}
+	return nil
+}
+
+type Stack struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	Id     string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
+	Name   string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
+	Status string `protobuf:"bytes,3,opt,name=status,proto3" json:"status,omitempty"`
+	Reason string `protobuf:"bytes,4,opt,name=reason,proto3" json:"reason,omitempty"`
+}
+
+func (x *Stack) Reset() {
+	*x = Stack{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_protos_compose_v1_compose_proto_msgTypes[6]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *Stack) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*Stack) ProtoMessage() {}
+
+func (x *Stack) ProtoReflect() protoreflect.Message {
+	mi := &file_protos_compose_v1_compose_proto_msgTypes[6]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use Stack.ProtoReflect.Descriptor instead.
+func (*Stack) Descriptor() ([]byte, []int) {
+	return file_protos_compose_v1_compose_proto_rawDescGZIP(), []int{6}
+}
+
+func (x *Stack) GetId() string {
+	if x != nil {
+		return x.Id
+	}
+	return ""
+}
+
+func (x *Stack) GetName() string {
+	if x != nil {
+		return x.Name
+	}
+	return ""
+}
+
+func (x *Stack) GetStatus() string {
+	if x != nil {
+		return x.Status
+	}
+	return ""
+}
+
+func (x *Stack) GetReason() string {
+	if x != nil {
+		return x.Reason
+	}
+	return ""
+}
+
+type ComposePsRequest struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	ProjectName string   `protobuf:"bytes,1,opt,name=projectName,proto3" json:"projectName,omitempty"`
+	WorkDir     string   `protobuf:"bytes,2,opt,name=workDir,proto3" json:"workDir,omitempty"`
+	Files       []string `protobuf:"bytes,3,rep,name=files,proto3" json:"files,omitempty"`
+}
+
+func (x *ComposePsRequest) Reset() {
+	*x = ComposePsRequest{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_protos_compose_v1_compose_proto_msgTypes[7]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *ComposePsRequest) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*ComposePsRequest) ProtoMessage() {}
+
+func (x *ComposePsRequest) ProtoReflect() protoreflect.Message {
+	mi := &file_protos_compose_v1_compose_proto_msgTypes[7]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use ComposePsRequest.ProtoReflect.Descriptor instead.
+func (*ComposePsRequest) Descriptor() ([]byte, []int) {
+	return file_protos_compose_v1_compose_proto_rawDescGZIP(), []int{7}
+}
+
+func (x *ComposePsRequest) GetProjectName() string {
+	if x != nil {
+		return x.ProjectName
+	}
+	return ""
+}
+
+func (x *ComposePsRequest) GetWorkDir() string {
+	if x != nil {
+		return x.WorkDir
+	}
+	return ""
+}
+
+func (x *ComposePsRequest) GetFiles() []string {
+	if x != nil {
+		return x.Files
+	}
+	return nil
+}
+
+type ComposePsResponse struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	Services []*Service `protobuf:"bytes,1,rep,name=services,proto3" json:"services,omitempty"`
+}
+
+func (x *ComposePsResponse) Reset() {
+	*x = ComposePsResponse{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_protos_compose_v1_compose_proto_msgTypes[8]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *ComposePsResponse) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*ComposePsResponse) ProtoMessage() {}
+
+func (x *ComposePsResponse) ProtoReflect() protoreflect.Message {
+	mi := &file_protos_compose_v1_compose_proto_msgTypes[8]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use ComposePsResponse.ProtoReflect.Descriptor instead.
+func (*ComposePsResponse) Descriptor() ([]byte, []int) {
+	return file_protos_compose_v1_compose_proto_rawDescGZIP(), []int{8}
+}
+
+func (x *ComposePsResponse) GetServices() []*Service {
+	if x != nil {
+		return x.Services
+	}
+	return nil
+}
+
+type Service struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	Id       string   `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
+	Name     string   `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
+	Replicas uint32   `protobuf:"varint,3,opt,name=replicas,proto3" json:"replicas,omitempty"`
+	Desired  uint32   `protobuf:"varint,4,opt,name=desired,proto3" json:"desired,omitempty"`
+	Ports    []string `protobuf:"bytes,5,rep,name=Ports,proto3" json:"Ports,omitempty"`
+}
+
+func (x *Service) Reset() {
+	*x = Service{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_protos_compose_v1_compose_proto_msgTypes[9]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *Service) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*Service) ProtoMessage() {}
+
+func (x *Service) ProtoReflect() protoreflect.Message {
+	mi := &file_protos_compose_v1_compose_proto_msgTypes[9]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use Service.ProtoReflect.Descriptor instead.
+func (*Service) Descriptor() ([]byte, []int) {
+	return file_protos_compose_v1_compose_proto_rawDescGZIP(), []int{9}
+}
+
+func (x *Service) GetId() string {
+	if x != nil {
+		return x.Id
+	}
+	return ""
+}
+
+func (x *Service) GetName() string {
+	if x != nil {
+		return x.Name
+	}
+	return ""
+}
+
+func (x *Service) GetReplicas() uint32 {
+	if x != nil {
+		return x.Replicas
+	}
+	return 0
+}
+
+func (x *Service) GetDesired() uint32 {
+	if x != nil {
+		return x.Desired
+	}
+	return 0
+}
+
+func (x *Service) GetPorts() []string {
+	if x != nil {
+		return x.Ports
+	}
+	return nil
+}
+
 var File_protos_compose_v1_compose_proto protoreflect.FileDescriptor
 
 var file_protos_compose_v1_compose_proto_rawDesc = []byte{
@@ -234,11 +631,55 @@ var file_protos_compose_v1_compose_proto_rawDesc = []byte{
 	0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x77, 0x6f, 0x72,
 	0x6b, 0x44, 0x69, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x77, 0x6f, 0x72, 0x6b,
 	0x44, 0x69, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03,
-	0x28, 0x09, 0x52, 0x05, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x22, 0x13, 0x0a, 0x11, 0x43, 0x6f, 0x6d,
-	0x70, 0x6f, 0x73, 0x65, 0x55, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x14,
-	0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x44, 0x6f, 0x77, 0x6e, 0x52, 0x65, 0x71,
-	0x75, 0x65, 0x73, 0x74, 0x22, 0x15, 0x0a, 0x13, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x44,
-	0x6f, 0x77, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x32, 0xed, 0x01, 0x0a, 0x07,
+	0x28, 0x09, 0x52, 0x05, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x22, 0x35, 0x0a, 0x11, 0x43, 0x6f, 0x6d,
+	0x70, 0x6f, 0x73, 0x65, 0x55, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x20,
+	0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20,
+	0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65,
+	0x22, 0x66, 0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x44, 0x6f, 0x77, 0x6e, 0x52,
+	0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63,
+	0x74, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f,
+	0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x77, 0x6f, 0x72, 0x6b,
+	0x44, 0x69, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x77, 0x6f, 0x72, 0x6b, 0x44,
+	0x69, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28,
+	0x09, 0x52, 0x05, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x22, 0x37, 0x0a, 0x13, 0x43, 0x6f, 0x6d, 0x70,
+	0x6f, 0x73, 0x65, 0x44, 0x6f, 0x77, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12,
+	0x20, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01,
+	0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d,
+	0x65, 0x22, 0x36, 0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x4c, 0x69, 0x73, 0x74,
+	0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65,
+	0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72,
+	0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x22, 0x56, 0x0a, 0x13, 0x43, 0x6f, 0x6d,
+	0x70, 0x6f, 0x73, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65,
+	0x12, 0x3f, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b,
+	0x32, 0x27, 0x2e, 0x63, 0x6f, 0x6d, 0x2e, 0x64, 0x6f, 0x63, 0x6b, 0x65, 0x72, 0x2e, 0x61, 0x70,
+	0x69, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65,
+	0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x52, 0x06, 0x73, 0x74, 0x61, 0x63, 0x6b,
+	0x73, 0x22, 0x5b, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64,
+	0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61,
+	0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x16,
+	0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06,
+	0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e,
+	0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x22, 0x64,
+	0x0a, 0x10, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x50, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65,
+	0x73, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d,
+	0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74,
+	0x4e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x77, 0x6f, 0x72, 0x6b, 0x44, 0x69, 0x72, 0x18,
+	0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x77, 0x6f, 0x72, 0x6b, 0x44, 0x69, 0x72, 0x12, 0x14,
+	0x0a, 0x05, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x05, 0x66,
+	0x69, 0x6c, 0x65, 0x73, 0x22, 0x5a, 0x0a, 0x11, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x50,
+	0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x45, 0x0a, 0x08, 0x73, 0x65, 0x72,
+	0x76, 0x69, 0x63, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x63, 0x6f,
+	0x6d, 0x2e, 0x64, 0x6f, 0x63, 0x6b, 0x65, 0x72, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x70, 0x72, 0x6f,
+	0x74, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x53,
+	0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x52, 0x08, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73,
+	0x22, 0x79, 0x0a, 0x07, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69,
+	0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e,
+	0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12,
+	0x1a, 0x0a, 0x08, 0x72, 0x65, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28,
+	0x0d, 0x52, 0x08, 0x72, 0x65, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x64,
+	0x65, 0x73, 0x69, 0x72, 0x65, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x07, 0x64, 0x65,
+	0x73, 0x69, 0x72, 0x65, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x6f, 0x72, 0x74, 0x73, 0x18, 0x05,
+	0x20, 0x03, 0x28, 0x09, 0x52, 0x05, 0x50, 0x6f, 0x72, 0x74, 0x73, 0x32, 0xd9, 0x03, 0x0a, 0x07,
 	0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x12, 0x6d, 0x0a, 0x02, 0x55, 0x70, 0x12, 0x32, 0x2e,
 	0x63, 0x6f, 0x6d, 0x2e, 0x64, 0x6f, 0x63, 0x6b, 0x65, 0x72, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x70,
 	0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x2e, 0x76, 0x31,
@@ -253,11 +694,26 @@ var file_protos_compose_v1_compose_proto_rawDesc = []byte{
 	0x75, 0x65, 0x73, 0x74, 0x1a, 0x35, 0x2e, 0x63, 0x6f, 0x6d, 0x2e, 0x64, 0x6f, 0x63, 0x6b, 0x65,
 	0x72, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6d,
 	0x70, 0x6f, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x44,
-	0x6f, 0x77, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x34, 0x5a, 0x32, 0x67,
-	0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x64, 0x6f, 0x63, 0x6b, 0x65, 0x72,
-	0x2f, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x2d, 0x63, 0x6c, 0x69, 0x2f, 0x70, 0x72, 0x6f,
-	0x74, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x76,
-	0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
+	0x6f, 0x77, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x75, 0x0a, 0x06, 0x53,
+	0x74, 0x61, 0x63, 0x6b, 0x73, 0x12, 0x34, 0x2e, 0x63, 0x6f, 0x6d, 0x2e, 0x64, 0x6f, 0x63, 0x6b,
+	0x65, 0x72, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x63, 0x6f,
+	0x6d, 0x70, 0x6f, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65,
+	0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x35, 0x2e, 0x63, 0x6f,
+	0x6d, 0x2e, 0x64, 0x6f, 0x63, 0x6b, 0x65, 0x72, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x70, 0x72, 0x6f,
+	0x74, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43,
+	0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
+	0x73, 0x65, 0x12, 0x73, 0x0a, 0x08, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x12, 0x32,
+	0x2e, 0x63, 0x6f, 0x6d, 0x2e, 0x64, 0x6f, 0x63, 0x6b, 0x65, 0x72, 0x2e, 0x61, 0x70, 0x69, 0x2e,
+	0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x2e, 0x76,
+	0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x50, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65,
+	0x73, 0x74, 0x1a, 0x33, 0x2e, 0x63, 0x6f, 0x6d, 0x2e, 0x64, 0x6f, 0x63, 0x6b, 0x65, 0x72, 0x2e,
+	0x61, 0x70, 0x69, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x6f,
+	0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x50, 0x73, 0x52,
+	0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x34, 0x5a, 0x32, 0x67, 0x69, 0x74, 0x68, 0x75,
+	0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x64, 0x6f, 0x63, 0x6b, 0x65, 0x72, 0x2f, 0x63, 0x6f, 0x6d,
+	0x70, 0x6f, 0x73, 0x65, 0x2d, 0x63, 0x6c, 0x69, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2f,
+	0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x76, 0x31, 0x62, 0x06, 0x70,
+	0x72, 0x6f, 0x74, 0x6f, 0x33,
 }
 
 var (
@@ -272,23 +728,35 @@ func file_protos_compose_v1_compose_proto_rawDescGZIP() []byte {
 	return file_protos_compose_v1_compose_proto_rawDescData
 }
 
-var file_protos_compose_v1_compose_proto_msgTypes = make([]protoimpl.MessageInfo, 4)
+var file_protos_compose_v1_compose_proto_msgTypes = make([]protoimpl.MessageInfo, 10)
 var file_protos_compose_v1_compose_proto_goTypes = []interface{}{
 	(*ComposeUpRequest)(nil),    // 0: com.docker.api.protos.compose.v1.ComposeUpRequest
 	(*ComposeUpResponse)(nil),   // 1: com.docker.api.protos.compose.v1.ComposeUpResponse
 	(*ComposeDownRequest)(nil),  // 2: com.docker.api.protos.compose.v1.ComposeDownRequest
 	(*ComposeDownResponse)(nil), // 3: com.docker.api.protos.compose.v1.ComposeDownResponse
+	(*ComposeListRequest)(nil),  // 4: com.docker.api.protos.compose.v1.ComposeListRequest
+	(*ComposeListResponse)(nil), // 5: com.docker.api.protos.compose.v1.ComposeListResponse
+	(*Stack)(nil),               // 6: com.docker.api.protos.compose.v1.Stack
+	(*ComposePsRequest)(nil),    // 7: com.docker.api.protos.compose.v1.ComposePsRequest
+	(*ComposePsResponse)(nil),   // 8: com.docker.api.protos.compose.v1.ComposePsResponse
+	(*Service)(nil),             // 9: com.docker.api.protos.compose.v1.Service
 }
 var file_protos_compose_v1_compose_proto_depIdxs = []int32{
-	0, // 0: com.docker.api.protos.compose.v1.Compose.Up:input_type -> com.docker.api.protos.compose.v1.ComposeUpRequest
-	2, // 1: com.docker.api.protos.compose.v1.Compose.Down:input_type -> com.docker.api.protos.compose.v1.ComposeDownRequest
-	1, // 2: com.docker.api.protos.compose.v1.Compose.Up:output_type -> com.docker.api.protos.compose.v1.ComposeUpResponse
-	3, // 3: com.docker.api.protos.compose.v1.Compose.Down:output_type -> com.docker.api.protos.compose.v1.ComposeDownResponse
-	2, // [2:4] is the sub-list for method output_type
-	0, // [0:2] is the sub-list for method input_type
-	0, // [0:0] is the sub-list for extension type_name
-	0, // [0:0] is the sub-list for extension extendee
-	0, // [0:0] is the sub-list for field type_name
+	6, // 0: com.docker.api.protos.compose.v1.ComposeListResponse.stacks:type_name -> com.docker.api.protos.compose.v1.Stack
+	9, // 1: com.docker.api.protos.compose.v1.ComposePsResponse.services:type_name -> com.docker.api.protos.compose.v1.Service
+	0, // 2: com.docker.api.protos.compose.v1.Compose.Up:input_type -> com.docker.api.protos.compose.v1.ComposeUpRequest
+	2, // 3: com.docker.api.protos.compose.v1.Compose.Down:input_type -> com.docker.api.protos.compose.v1.ComposeDownRequest
+	4, // 4: com.docker.api.protos.compose.v1.Compose.Stacks:input_type -> com.docker.api.protos.compose.v1.ComposeListRequest
+	7, // 5: com.docker.api.protos.compose.v1.Compose.Services:input_type -> com.docker.api.protos.compose.v1.ComposePsRequest
+	1, // 6: com.docker.api.protos.compose.v1.Compose.Up:output_type -> com.docker.api.protos.compose.v1.ComposeUpResponse
+	3, // 7: com.docker.api.protos.compose.v1.Compose.Down:output_type -> com.docker.api.protos.compose.v1.ComposeDownResponse
+	5, // 8: com.docker.api.protos.compose.v1.Compose.Stacks:output_type -> com.docker.api.protos.compose.v1.ComposeListResponse
+	8, // 9: com.docker.api.protos.compose.v1.Compose.Services:output_type -> com.docker.api.protos.compose.v1.ComposePsResponse
+	6, // [6:10] is the sub-list for method output_type
+	2, // [2:6] is the sub-list for method input_type
+	2, // [2:2] is the sub-list for extension type_name
+	2, // [2:2] is the sub-list for extension extendee
+	0, // [0:2] is the sub-list for field type_name
 }
 
 func init() { file_protos_compose_v1_compose_proto_init() }
@@ -345,6 +813,78 @@ func file_protos_compose_v1_compose_proto_init() {
 				return nil
 			}
 		}
+		file_protos_compose_v1_compose_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*ComposeListRequest); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
+		file_protos_compose_v1_compose_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*ComposeListResponse); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
+		file_protos_compose_v1_compose_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*Stack); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
+		file_protos_compose_v1_compose_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*ComposePsRequest); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
+		file_protos_compose_v1_compose_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*ComposePsResponse); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
+		file_protos_compose_v1_compose_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*Service); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
 	}
 	type x struct{}
 	out := protoimpl.TypeBuilder{
@@ -352,7 +892,7 @@ func file_protos_compose_v1_compose_proto_init() {
 			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
 			RawDescriptor: file_protos_compose_v1_compose_proto_rawDesc,
 			NumEnums:      0,
-			NumMessages:   4,
+			NumMessages:   10,
 			NumExtensions: 0,
 			NumServices:   1,
 		},
@@ -380,6 +920,8 @@ const _ = grpc.SupportPackageIsVersion6
 type ComposeClient interface {
 	Up(ctx context.Context, in *ComposeUpRequest, opts ...grpc.CallOption) (*ComposeUpResponse, error)
 	Down(ctx context.Context, in *ComposeDownRequest, opts ...grpc.CallOption) (*ComposeDownResponse, error)
+	Stacks(ctx context.Context, in *ComposeListRequest, opts ...grpc.CallOption) (*ComposeListResponse, error)
+	Services(ctx context.Context, in *ComposePsRequest, opts ...grpc.CallOption) (*ComposePsResponse, error)
 }
 
 type composeClient struct {
@@ -408,10 +950,30 @@ func (c *composeClient) Down(ctx context.Context, in *ComposeDownRequest, opts .
 	return out, nil
 }
 
+func (c *composeClient) Stacks(ctx context.Context, in *ComposeListRequest, opts ...grpc.CallOption) (*ComposeListResponse, error) {
+	out := new(ComposeListResponse)
+	err := c.cc.Invoke(ctx, "/com.docker.api.protos.compose.v1.Compose/Stacks", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
+func (c *composeClient) Services(ctx context.Context, in *ComposePsRequest, opts ...grpc.CallOption) (*ComposePsResponse, error) {
+	out := new(ComposePsResponse)
+	err := c.cc.Invoke(ctx, "/com.docker.api.protos.compose.v1.Compose/Services", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
 // ComposeServer is the server API for Compose service.
 type ComposeServer interface {
 	Up(context.Context, *ComposeUpRequest) (*ComposeUpResponse, error)
 	Down(context.Context, *ComposeDownRequest) (*ComposeDownResponse, error)
+	Stacks(context.Context, *ComposeListRequest) (*ComposeListResponse, error)
+	Services(context.Context, *ComposePsRequest) (*ComposePsResponse, error)
 }
 
 // UnimplementedComposeServer can be embedded to have forward compatible implementations.
@@ -424,6 +986,12 @@ func (*UnimplementedComposeServer) Up(context.Context, *ComposeUpRequest) (*Comp
 func (*UnimplementedComposeServer) Down(context.Context, *ComposeDownRequest) (*ComposeDownResponse, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method Down not implemented")
 }
+func (*UnimplementedComposeServer) Stacks(context.Context, *ComposeListRequest) (*ComposeListResponse, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method Stacks not implemented")
+}
+func (*UnimplementedComposeServer) Services(context.Context, *ComposePsRequest) (*ComposePsResponse, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method Services not implemented")
+}
 
 func RegisterComposeServer(s *grpc.Server, srv ComposeServer) {
 	s.RegisterService(&_Compose_serviceDesc, srv)
@@ -465,6 +1033,42 @@ func _Compose_Down_Handler(srv interface{}, ctx context.Context, dec func(interf
 	return interceptor(ctx, in, info, handler)
 }
 
+func _Compose_Stacks_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(ComposeListRequest)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(ComposeServer).Stacks(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/com.docker.api.protos.compose.v1.Compose/Stacks",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(ComposeServer).Stacks(ctx, req.(*ComposeListRequest))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
+func _Compose_Services_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(ComposePsRequest)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(ComposeServer).Services(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/com.docker.api.protos.compose.v1.Compose/Services",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(ComposeServer).Services(ctx, req.(*ComposePsRequest))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
 var _Compose_serviceDesc = grpc.ServiceDesc{
 	ServiceName: "com.docker.api.protos.compose.v1.Compose",
 	HandlerType: (*ComposeServer)(nil),
@@ -477,6 +1081,14 @@ var _Compose_serviceDesc = grpc.ServiceDesc{
 			MethodName: "Down",
 			Handler:    _Compose_Down_Handler,
 		},
+		{
+			MethodName: "Stacks",
+			Handler:    _Compose_Stacks_Handler,
+		},
+		{
+			MethodName: "Services",
+			Handler:    _Compose_Services_Handler,
+		},
 	},
 	Streams:  []grpc.StreamDesc{},
 	Metadata: "protos/compose/v1/compose.proto",
diff --git a/protos/compose/v1/compose.proto b/protos/compose/v1/compose.proto
index fbe9a31b..5feadc38 100644
--- a/protos/compose/v1/compose.proto
+++ b/protos/compose/v1/compose.proto
@@ -22,6 +22,8 @@ option go_package = "github.com/docker/compose-cli/protos/compose/v1;v1";
 service Compose {
   rpc Up(ComposeUpRequest) returns (ComposeUpResponse);
   rpc Down(ComposeDownRequest) returns (ComposeDownResponse);
+  rpc Stacks(ComposeListRequest)returns (ComposeListResponse);
+  rpc Services(ComposePsRequest)returns (ComposePsResponse);
 }
 
 message ComposeUpRequest {
@@ -31,10 +33,48 @@ message ComposeUpRequest {
 }
 
 message ComposeUpResponse {
+  string projectName = 1;
 }
 
 message ComposeDownRequest {
+  string projectName = 1;
+  string workDir = 2;
+  repeated string files = 3;
 }
 
 message ComposeDownResponse {
+  string projectName = 1;
+}
+
+message ComposeListRequest {
+  string projectName = 1;
+}
+
+message ComposeListResponse {
+  repeated Stack stacks = 1;
+}
+
+message Stack {
+	string id = 1;
+	string name = 2;
+	string status = 3;
+	string reason = 4;
+}
+
+message ComposePsRequest {
+  string projectName = 1;
+  string workDir = 2;
+  repeated string files = 3;
+}
+
+message ComposePsResponse {
+  repeated Service services = 1;
+}
+
+message Service {
+  string id = 1;
+	string name = 2;
+	uint32 replicas = 3;
+	uint32 desired = 4;
+	repeated string Ports = 5;
 }
diff --git a/server/metrics.go b/server/metrics.go
index b465981f..bbd1131e 100644
--- a/server/metrics.go
+++ b/server/metrics.go
@@ -43,6 +43,10 @@ var (
 		"/com.docker.api.protos.volumes.v1.Volumes/VolumesDelete":  "volume rm",
 		"/com.docker.api.protos.volumes.v1.Volumes/VolumesCreate":  "volume create",
 		"/com.docker.api.protos.volumes.v1.Volumes/VolumesInspect": "volume inspect",
+		"/com.docker.api.protos.compose.v1.Compose/Up":             "compose up",
+		"/com.docker.api.protos.compose.v1.Compose/Down":           "compose down",
+		"/com.docker.api.protos.compose.v1.Compose/Stacks":         "compose ls",
+		"/com.docker.api.protos.compose.v1.Compose/Services":       "compose ps",
 	}
 )
 
diff --git a/server/proxy/compose.go b/server/proxy/compose.go
new file mode 100644
index 00000000..a903c05c
--- /dev/null
+++ b/server/proxy/compose.go
@@ -0,0 +1,97 @@
+/*
+   Copyright 2020 Docker Compose CLI authors
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+*/
+
+package proxy
+
+import (
+	"context"
+
+	"github.com/compose-spec/compose-go/cli"
+	"github.com/compose-spec/compose-go/types"
+
+	composev1 "github.com/docker/compose-cli/protos/compose/v1"
+)
+
+func (p *proxy) Up(ctx context.Context, request *composev1.ComposeUpRequest) (*composev1.ComposeUpResponse, error) {
+	project, err := getComposeProject(request.Files, request.WorkDir, request.ProjectName)
+	if err != nil {
+		return nil, err
+	}
+	return &composev1.ComposeUpResponse{ProjectName: project.Name}, Client(ctx).ComposeService().Up(ctx, project, true)
+}
+
+func (p *proxy) Down(ctx context.Context, request *composev1.ComposeDownRequest) (*composev1.ComposeDownResponse, error) {
+	projectName := request.GetProjectName()
+	if projectName == "" {
+		project, err := getComposeProject(request.Files, request.WorkDir, request.ProjectName)
+		if err != nil {
+			return nil, err
+		}
+		projectName = project.Name
+	}
+	return &composev1.ComposeDownResponse{ProjectName: projectName}, Client(ctx).ComposeService().Down(ctx, projectName)
+}
+
+func (p *proxy) Services(ctx context.Context, request *composev1.ComposePsRequest) (*composev1.ComposePsResponse, error) {
+	projectName := request.GetProjectName()
+	if projectName == "" {
+		project, err := getComposeProject(request.Files, request.WorkDir, request.ProjectName)
+		if err != nil {
+			return nil, err
+		}
+		projectName = project.Name
+	}
+	services, err := Client(ctx).ComposeService().Ps(ctx, projectName)
+	if err != nil {
+		return nil, err
+	}
+	response := []*composev1.Service{}
+	for _, service := range services {
+		response = append(response, &composev1.Service{
+			Id:       service.ID,
+			Name:     service.Name,
+			Replicas: uint32(service.Replicas),
+			Desired:  uint32(service.Desired),
+			Ports:    service.Ports,
+		})
+	}
+	return &composev1.ComposePsResponse{Services: response}, nil
+}
+
+func (p *proxy) Stacks(ctx context.Context, request *composev1.ComposeListRequest) (*composev1.ComposeListResponse, error) {
+	stacks, err := Client(ctx).ComposeService().List(ctx, request.ProjectName)
+	if err != nil {
+		return nil, err
+	}
+	response := []*composev1.Stack{}
+	for _, stack := range stacks {
+		response = append(response, &composev1.Stack{
+			Id:     stack.ID,
+			Name:   stack.Name,
+			Status: stack.Status,
+			Reason: stack.Reason,
+		})
+	}
+	return &composev1.ComposeListResponse{Stacks: response}, nil
+}
+
+func getComposeProject(files []string, workingDir string, projectName string) (*types.Project, error) {
+	options, err := cli.NewProjectOptions(files, cli.WithWorkingDirectory(workingDir), cli.WithName(projectName))
+	if err != nil {
+		return nil, err
+	}
+	return cli.ProjectFromOptions(options)
+}
diff --git a/server/proxy/proxy.go b/server/proxy/proxy.go
index 468b5b9a..89f46b6a 100644
--- a/server/proxy/proxy.go
+++ b/server/proxy/proxy.go
@@ -22,6 +22,7 @@ import (
 
 	"github.com/docker/compose-cli/api/client"
 	"github.com/docker/compose-cli/config"
+	composev1 "github.com/docker/compose-cli/protos/compose/v1"
 	containersv1 "github.com/docker/compose-cli/protos/containers/v1"
 	contextsv1 "github.com/docker/compose-cli/protos/contexts/v1"
 	streamsv1 "github.com/docker/compose-cli/protos/streams/v1"
@@ -45,6 +46,7 @@ func Client(ctx context.Context) *client.Client {
 // Proxy implements the gRPC server and forwards the actions
 // to the right backend
 type Proxy interface {
+	composev1.ComposeServer
 	containersv1.ContainersServer
 	streamsv1.StreamingServer
 	volumesv1.VolumesServer


Test patch:
diff --git a/cli/cmd/testdata/inspect-out-id.golden b/cli/cmd/testdata/inspect-out-id.golden
index 1200c98e..517629f4 100644
--- a/cli/cmd/testdata/inspect-out-id.golden
+++ b/cli/cmd/testdata/inspect-out-id.golden
@@ -2,6 +2,11 @@
     "ID": "id",
     "Status": "",
     "Image": "nginx",
+    "Command": "",
+    "CPUTime": 0,
+    "MemoryUsage": 0,
+    "PidsCurrent": 0,
+    "PidsLimit": 0,
     "HostConfig": {
         "RestartPolicy": "none",
         "CPUReservation": 0,
@@ -10,5 +15,13 @@
         "MemoryLimit": 0,
         "AutoRemove": false
     },
-    "Platform": "Linux"
+    "Platform": "Linux",
+    "Healthcheck": {
+        "Disable": false,
+        "Test": null,
+        "Interval": "0s",
+        "Retries": 0,
+        "StartPeriod": "0s",
+        "Timeout": "0s"
+    }
 }
diff --git a/ecs/cloudformation_test.go b/ecs/cloudformation_test.go
index 275721c3..c8d92c94 100644
--- a/ecs/cloudformation_test.go
+++ b/ecs/cloudformation_test.go
@@ -315,21 +315,6 @@ services:
             - discrete_resource_spec:
                 kind: gpus
                 value: 2
-`, useDefaultVPC, useGPU)
-	def = template.Resources["TestTaskDefinition"].(*ecs.TaskDefinition)
-	assert.Equal(t, def.Cpu, "")
-	assert.Equal(t, def.Memory, "")
-
-	template = convertYaml(t, `
-services:
-  test:
-    image: nginx
-    deploy:
-      resources:
-        reservations:
-          devices: 
-            - capabilities: [gpu]
-              count: 2
 `, useDefaultVPC, useGPU)
 	def = template.Resources["TestTaskDefinition"].(*ecs.TaskDefinition)
 	assert.Equal(t, def.Cpu, "")
diff --git a/server/metrics_test.go b/server/metrics_test.go
index 9c275230..3b47c7ef 100644
--- a/server/metrics_test.go
+++ b/server/metrics_test.go
@@ -35,6 +35,7 @@ import (
 	"github.com/docker/compose-cli/api/volumes"
 	"github.com/docker/compose-cli/errdefs"
 	"github.com/docker/compose-cli/metrics"
+	composev1 "github.com/docker/compose-cli/protos/compose/v1"
 	containersv1 "github.com/docker/compose-cli/protos/containers/v1"
 	contextsv1 "github.com/docker/compose-cli/protos/contexts/v1"
 	streamsv1 "github.com/docker/compose-cli/protos/streams/v1"
@@ -105,6 +106,7 @@ func setupServer() *grpc.Server {
 	ctx := context.TODO()
 	s := New(ctx)
 	p := proxy.New(ctx)
+	composev1.RegisterComposeServer(s, p)
 	containersv1.RegisterContainersServer(s, p)
 	streamsv1.RegisterStreamingServer(s, p)
 	volumesv1.RegisterVolumesServer(s, p)
diff --git a/tests/aci-e2e/e2e-aci_test.go b/tests/aci-e2e/e2e-aci_test.go
index d3820dcd..50693931 100644
--- a/tests/aci-e2e/e2e-aci_test.go
+++ b/tests/aci-e2e/e2e-aci_test.go
@@ -17,9 +17,7 @@
 package main
 
 import (
-	"bytes"
 	"context"
-	"encoding/json"
 	"errors"
 	"fmt"
 	"io/ioutil"
@@ -51,7 +49,6 @@ import (
 	"github.com/docker/compose-cli/aci/convert"
 	"github.com/docker/compose-cli/aci/login"
 	"github.com/docker/compose-cli/api/containers"
-	"github.com/docker/compose-cli/cli/cmd"
 	"github.com/docker/compose-cli/context/store"
 	"github.com/docker/compose-cli/errdefs"
 	. "github.com/docker/compose-cli/tests/framework"
@@ -274,7 +271,7 @@ func TestRunVolume(t *testing.T) {
 	t.Run("inspect", func(t *testing.T) {
 		res := c.RunDockerCmd("inspect", container)
 
-		containerInspect, err := parseContainerInspect(res.Stdout())
+		containerInspect, err := ParseContainerInspect(res.Stdout())
 		assert.NilError(t, err)
 		assert.Equal(t, containerInspect.Platform, "Linux")
 		assert.Equal(t, containerInspect.HostConfig.CPULimit, 1.0)
@@ -421,7 +418,7 @@ func TestContainerRunAttached(t *testing.T) {
 
 		inspectRes := c.RunDockerCmd("inspect", container)
 
-		containerInspect, err := parseContainerInspect(inspectRes.Stdout())
+		containerInspect, err := ParseContainerInspect(inspectRes.Stdout())
 		assert.NilError(t, err)
 		assert.Equal(t, containerInspect.Platform, "Linux")
 		assert.Equal(t, containerInspect.HostConfig.CPULimit, 0.1)
@@ -552,10 +549,10 @@ func TestUpSecretsResources(t *testing.T) {
 	})
 
 	res := c.RunDockerCmd("inspect", web1)
-	web1Inspect, err := parseContainerInspect(res.Stdout())
+	web1Inspect, err := ParseContainerInspect(res.Stdout())
 	assert.NilError(t, err)
 	res = c.RunDockerCmd("inspect", web2)
-	web2Inspect, err := parseContainerInspect(res.Stdout())
+	web2Inspect, err := ParseContainerInspect(res.Stdout())
 	assert.NilError(t, err)
 
 	t.Run("read secrets in service 1", func(t *testing.T) {
@@ -596,11 +593,11 @@ func TestUpSecretsResources(t *testing.T) {
 	})
 
 	t.Run("check healthchecks inspect", func(t *testing.T) {
-		assert.Assert(t, web1Inspect.Healthcheck != nil)
-		assert.Equal(t, time.Duration(*web1Inspect.Healthcheck.Interval), 5*time.Second)
+		assert.Equal(t, web1Inspect.Healthcheck.Disable, false)
+		assert.Equal(t, time.Duration(web1Inspect.Healthcheck.Interval), 5*time.Second)
 		assert.DeepEqual(t, web1Inspect.Healthcheck.Test, []string{"curl", "-f", "http://localhost:80/healthz"})
 
-		assert.Assert(t, web2Inspect.Healthcheck == nil)
+		assert.Equal(t, web2Inspect.Healthcheck.Disable, true)
 	})
 
 	t.Run("healthcheck restart failed app", func(t *testing.T) {
@@ -626,7 +623,7 @@ func TestUpSecretsResources(t *testing.T) {
 		poll.WaitOn(t, checkLogsReset, poll.WithDelay(5*time.Second), poll.WithTimeout(90*time.Second))
 
 		res := c.RunDockerCmd("inspect", web1)
-		web1Inspect, err = parseContainerInspect(res.Stdout())
+		web1Inspect, err = ParseContainerInspect(res.Stdout())
 		assert.Equal(t, web1Inspect.Status, "Running")
 	})
 }
@@ -700,7 +697,7 @@ func TestUpUpdate(t *testing.T) {
 
 		res = c.RunDockerCmd("inspect", serverContainer)
 
-		containerInspect, err := parseContainerInspect(res.Stdout())
+		containerInspect, err := ParseContainerInspect(res.Stdout())
 		assert.NilError(t, err)
 		assert.Assert(t, is.Len(containerInspect.Ports, 1))
 		endpoint := fmt.Sprintf("http://%s:%d", containerInspect.Ports[0].HostIP, containerInspect.Ports[0].HostPort)
@@ -784,7 +781,7 @@ func TestUpUpdate(t *testing.T) {
 		for _, cName := range []string{serverContainer, wordsContainer} {
 			res = c.RunDockerCmd("inspect", cName)
 
-			containerInspect, err := parseContainerInspect(res.Stdout())
+			containerInspect, err := ParseContainerInspect(res.Stdout())
 			assert.NilError(t, err)
 			assert.Assert(t, is.Len(containerInspect.Ports, 1))
 			endpoint := fmt.Sprintf("http://%s:%d", containerInspect.Ports[0].HostIP, containerInspect.Ports[0].HostPort)
@@ -952,7 +949,7 @@ func getContainerName(stdout string) string {
 func waitForStatus(t *testing.T, c *E2eCLI, containerID string, statuses ...string) {
 	checkStopped := func(logt poll.LogT) poll.Result {
 		res := c.RunDockerCmd("inspect", containerID)
-		containerInspect, err := parseContainerInspect(res.Stdout())
+		containerInspect, err := ParseContainerInspect(res.Stdout())
 		assert.NilError(t, err)
 		for _, status := range statuses {
 			if containerInspect.Status == status {
@@ -965,15 +962,6 @@ func waitForStatus(t *testing.T, c *E2eCLI, containerID string, statuses ...stri
 	poll.WaitOn(t, checkStopped, poll.WithDelay(5*time.Second), poll.WithTimeout(90*time.Second))
 }
 
-func parseContainerInspect(stdout string) (*cmd.ContainerInspectView, error) {
-	var res cmd.ContainerInspectView
-	rdr := bytes.NewReader([]byte(stdout))
-	if err := json.NewDecoder(rdr).Decode(&res); err != nil {
-		return nil, err
-	}
-	return &res, nil
-}
-
 func waitWithTimeout(blockingCall func(), timeout time.Duration) error {
 	c := make(chan struct{})
 	go func() {
diff --git a/tests/e2e/testdata/inspect-id.golden b/tests/e2e/testdata/inspect-id.golden
index 1200c98e..517629f4 100644
--- a/tests/e2e/testdata/inspect-id.golden
+++ b/tests/e2e/testdata/inspect-id.golden
@@ -2,6 +2,11 @@
     "ID": "id",
     "Status": "",
     "Image": "nginx",
+    "Command": "",
+    "CPUTime": 0,
+    "MemoryUsage": 0,
+    "PidsCurrent": 0,
+    "PidsLimit": 0,
     "HostConfig": {
         "RestartPolicy": "none",
         "CPUReservation": 0,
@@ -10,5 +15,13 @@
         "MemoryLimit": 0,
         "AutoRemove": false
     },
-    "Platform": "Linux"
+    "Platform": "Linux",
+    "Healthcheck": {
+        "Disable": false,
+        "Test": null,
+        "Interval": "0s",
+        "Retries": 0,
+        "StartPeriod": "0s",
+        "Timeout": "0s"
+    }
 }
diff --git a/tests/framework/e2e.go b/tests/framework/e2e.go
index edf450c0..ee500ca6 100644
--- a/tests/framework/e2e.go
+++ b/tests/framework/e2e.go
@@ -17,6 +17,8 @@
 package framework
 
 import (
+	"bytes"
+	"encoding/json"
 	"errors"
 	"fmt"
 	"io/ioutil"
@@ -33,6 +35,8 @@ import (
 	is "gotest.tools/v3/assert/cmp"
 	"gotest.tools/v3/icmd"
 	"gotest.tools/v3/poll"
+
+	"github.com/docker/compose-cli/api/containers"
 )
 
 var (
@@ -192,6 +196,17 @@ func GoldenFile(name string) string {
 	return name + ".golden"
 }
 
+// ParseContainerInspect parses the output of a `docker inspect` command for a
+// container
+func ParseContainerInspect(stdout string) (*containers.Container, error) {
+	var res containers.Container
+	rdr := bytes.NewReader([]byte(stdout))
+	if err := json.NewDecoder(rdr).Decode(&res); err != nil {
+		return nil, err
+	}
+	return &res, nil
+}
+
 // HTTPGetWithRetry performs an HTTP GET on an `endpoint`, using retryDelay also as a request timeout.
 // In the case of an error or the response status is not the expeted one, it retries the same request,
 // returning the response body as a string (empty if we could not reach it)