Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Docker on Windows: Interactive TTY Session Gives “Cannot Enable TTY Mode on Non-TTY Input”

DZone's Guide to

Docker on Windows: Interactive TTY Session Gives “Cannot Enable TTY Mode on Non-TTY Input”

When running a Docker shell container on Windows 7, you'll get a very specific error. Luckily, there's a simple workaround.

· Integration Zone
Free Resource

Modernize your application architectures with microservices and APIs with best practices from this free virtual summit series. Brought to you in partnership with CA Technologies.

Trying to run a shell into a running container (docker exec -it containerid bash) using DockerToolbox/docker-machine on Windows 7 gives this error:

"cannot enable tty mode on non tty input"

(this runs fine on Mac OS X)

This is logged as an issue here. As a workaround, prefix the docker command with winpty, so:

winpty docker exec -it containerid bash

The Integration Zone is proudly sponsored by CA Technologies. Learn from expert microservices and API presentations at the Modernizing Application Architectures Virtual Summit Series.

Topics:
integration ,docker ,windows 7

Published at DZone with permission of Kevin Hooke, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}