參考資料
https://ithelp.ithome.com.tw/articles/10191634
https://joshhu.gitbooks.io/dockercomman ... Basic.html
Container執行時的操作
create:建立Container並執行指令
run:同create
kill:刪除執行中的Container,但Container還是存在,只是死了。
rm:刪除Container(停止或運行中都行),Container就從這世上消失了
pause:暫停執行中的Container,仍暫有記憶體停,服務不中斷
unpause:恢復暫停中的Container
stop:停止執行中的Container,但不暫有記憶體,服務中斷
start:啟動停止中的Container
restart:重新啟動Container
wait:讓Container暫停直到Container停止為止
rename:更名Container
Container的狀態
inspect:檢查Container的狀態(非常常用)
stats:查看Container的CPU、記憶體及網路使用
port:查看Container的通訊埠使用
ps:查看Container使用狀態
top:查看Container在主系統中的記憶體使用
dip:查看Container的IP
dpid:查看Container的pid