1. 程式人生 > >Error: Cannot perform an interactive login from a non TTY device

Error: Cannot perform an interactive login from a non TTY device

Docker on Windows: interactive tty session gives “cannot enable tty mode on non tty input”

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