windows上执行Docker命令,如:mysql
docker exec -it mysql mysql -uroot -p
复制代码
就会报错:sql
the input device is not a TTY. If you are using mintty, try prefixing the command with 'winpty'
复制代码
须要在执行Docker命令以前,加 winpty,如:docker
winpty docker exec -it mysql mysql -uroot -p
复制代码