After installing docker under windows, the operation docker run -it ubuntu /bin/bash
fails and the error "cannot enable tty mode on non tty input" is displayed.
Reference link to solve the problem
in conclusion
I have used both options myself with success.
The first is to add winpty in front of the command
winpty docker run -it ubuntu
The second option is better (why feel it for yourself)
docker-machine ssh defaultdocker run -it ubuntu /bin/bash
Some specific reasons and principles are mentioned in the link above, but I just pay attention to the problem has been solved, so I did not look carefully. Roughly, this problem is generated by tools such as MINGW64, not by docker itself. And this issue has not been closed, so there should be a better solution in the future.