From 7b2fa4837819c99fe8ccbaa116a75439c7d57588 Mon Sep 17 00:00:00 2001 From: "Dr. Stefan Schimanski" Date: Thu, 9 Mar 2017 13:18:45 +0100 Subject: [PATCH] UPSTREAM: docker/engine-api: 26718: Add Logs to ContainerAttachOptions This is docker/docker PR 26718 because docker has reintegrated engine-api into the primary docker repo. --- vendor/github.com/docker/engine-api/client/container_attach.go | 3 +++ vendor/github.com/docker/engine-api/types/client.go | 1 + 2 files changed, 4 insertions(+) diff --git a/vendor/github.com/docker/engine-api/client/container_attach.go b/vendor/github.com/docker/engine-api/client/container_attach.go index 1b616bf038519..1d3634790398f 100644 --- a/vendor/github.com/docker/engine-api/client/container_attach.go +++ b/vendor/github.com/docker/engine-api/client/container_attach.go @@ -28,6 +28,9 @@ func (cli *Client) ContainerAttach(ctx context.Context, container string, option if options.DetachKeys != "" { query.Set("detachKeys", options.DetachKeys) } + if options.Logs { + query.Set("logs", "1") + } headers := map[string][]string{"Content-Type": {"text/plain"}} return cli.postHijacked(ctx, "/containers/"+container+"/attach", query, nil, headers) diff --git a/vendor/github.com/docker/engine-api/types/client.go b/vendor/github.com/docker/engine-api/types/client.go index fa3b2cfb458ca..1d2f5f1a3150a 100644 --- a/vendor/github.com/docker/engine-api/types/client.go +++ b/vendor/github.com/docker/engine-api/types/client.go @@ -17,6 +17,7 @@ type ContainerAttachOptions struct { Stdout bool Stderr bool DetachKeys string + Logs bool } // ContainerCommitOptions holds parameters to commit changes into a container.