简体   繁体   中英

How to debug Docker?

I want to know how you have to debug docker. So I have a command which is giving a timeout and I want to debug it:

It's a command to access my docker registry:

docker login -u admin -e my@mail.com -p $(oc whoami -t) 172.30.xx.xx:5000

I read a lot about using docker daemon -d but that gives a lot of output and it remains running. How do I have to use docker daemon to debug just my executing command? Is this possible or what's the best way to debug this issue. Thanks

You could try just running docker daemon (no -d ) as that will give less output and may still provide some useful information as to what went wrong.

As for the fact the daemon command keeps running, this is unavoidable unless docker itself crashes. I would suggest running the daemon command, quickly running the docker login command, then Ctrl-C the daemon command to save reading lots.

Another thing is make sure you have stopped all other instances of docker first before running the daemon command ( sudo service docker stop on Ubuntu for example).

I would suggest you to look into your private Docker Registry logs.

By the way, how did you implemented the authentication for your Registry? Also, are SSL certs on your local machine are OK?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM