首页 > Web开发 > 详细

[Docker] Debug a Node.js Container

时间:2021-03-30 00:20:38      阅读:22      评论:0      收藏:0      [点我收藏+]

1. Pull the docker image

docker pull isjustintime/debug-me:latest

 

2. Run the image:

docker run -d isjustintime/debug-me

 

3. Check docker is running:

docker ps

 

4. See the docker inspect for more imformation:

docker inspect 0d8a85a50e1c

 

5. Get into container

docker exec -it 0d8a85a50e1c sh

 Inside container, you can use all linux cmds:

pwd # /usr/src/app

See what process are running

技术分享图片

 

6. Exit container cmd

# exit

 

7. See the docker logs:

docker logs 0d8a85a50e1c

Seeing:

ReferenceError: getData is not defined

 

[Docker] Debug a Node.js Container

原文:https://www.cnblogs.com/Answer1215/p/14594366.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!