get stdout logs

This commit is contained in:
Stefan Schwarz 2020-12-28 02:39:56 +01:00
parent 9785bd983b
commit bfa35c8640
1 changed files with 3 additions and 1 deletions

View File

@ -32,7 +32,9 @@ func main() {
if err != nil {
log.Fatalf("unread: %s", err)
}
logs, err := cli.ContainerLogs(context.TODO(), containerName, types.ContainerLogsOptions{})
logs, err := cli.ContainerLogs(context.TODO(), containerName, types.ContainerLogsOptions{
ShowStdout: true,
})
if err != nil {
log.Fatalf("unread: %s", err)
}