Skip to content

Latest commit

 

History

History
24 lines (18 loc) · 965 Bytes

README.md

File metadata and controls

24 lines (18 loc) · 965 Bytes

docker-debug

Have you ever wanted to easily debug a container using FROM scratch? I have. When I went looking for a better way to do this, I came across this article, and then set about building this image.

The most important part is knowing how to attach the container to the same namespace as the application that you'd like to debug.

docker run -it \
    --pid=container:<target container name> \
    --net=container:<target container name> \
    --cap-add sys_admin \
    --cap-add sys_ptrace \
    invisiblethreat/docker-debug:latest

The default session drops you into a tmux session running this configuration.

Make it yours!

I'm happy to accept PRs, but maybe you'd have more fun if you forked the repo and made something that is custom just for you!