0
我有一個運行play Web應用程序的docker映像。在dockerfile中有CMD啓動服務器,它等待,直到你按Ctrl + D退出。如果我這樣做:Docker在啓動時退出CMD
docker run -d -i -v
它工作正常 - 啓動服務器並等待ctrl + D。
但是,這是不是這樣的,當我啓動容器:
docker start -i
相反,服務器會自動停止:
--- (Running the application, auto-reloading is enabled) ---
[info] p.c.s.NettyServer - Listening for HTTP on /0:0:0:0:0:0:0:0:9000
(Server started, use Ctrl+D to stop and go back to the console...)
[success] Total time: 1 s, completed Jul 27, 2016 11:54:13 AM <--- this indicates that the server was stopped.
我怎樣才能迫使碼頭工人開始不停的服務器?