Sunday, May 26, 2019

SSH into a running Linux container - docker

Looking for extensive set of commands, refer

 In summary, use below commands as specified in article

  • Use docker ps to get the name of the existing container
  • Use the command docker exec -it {containername} /bin/bash to get a bash shell in the container
  • Generically, use docker exec -it {containername} {command} to execute whatever command you specify in the container.

running docker as root user 
docker exec -it --user root {container id} /bin/bash

No comments:

Why do we use np.random.seed()

This is a simple function but to my surprise lot of ML engineers had asked me about the actual usage of this function and why do I use it wh...