Home  >  Q&A  >  body text

docker守护运行老是自己退出怎么回事啊?

我用Dockerfile生成镜像,CMD运行了sh脚本启动lnmp所有服务,现在是终端进去重新启动lnmp服务,一切ok,用-d启动后再查看就是退出状态,不知该如何调整…

ringa_leeringa_lee2758 days ago575

reply all(2)I'll reply

  • 迷茫

    迷茫2017-04-24 09:11:29

    Because lnmp is not a continuously running command, it will not run in the background.
    Let’s start the container through docker start.

    reply
    0
  • 迷茫

    迷茫2017-04-24 09:11:29

    Dockerfile file writing problems, for example, the JAVA service container TOMCAT cannot be successfully started using startup.sh and needs to be replaced with catalina.sh.

    reply
    0
  • Cancelreply