Docker Run command hangs without any error

Yogesh H Shenoy picture Yogesh H Shenoy · Sep 7, 2017 · Viewed 13.8k times · Source

I have been working with docker in Windows Server 2016 only for the last two weeks. I am trying to run a html file using

microsoft/windowsservercore (docker image)

After I execute the command

docker run -it --name CoreServerCMD microsoft/windowsservercore cmd.exe

the execution hangs and do not return.

please help this is image reference:

Error

Answer

Avik Aggarwal picture Avik Aggarwal · Mar 6, 2019

You are running the 'docker run' command with '-it' flag. You need to include '-d' flag instead of '-it'.