docker-exec-cli
v1.0.1
Published
Wrapper around docker exec so you can run commands in your container by image name
Downloads
3
Readme
Docker Exec
This module is a tiny CLI tool that runs docker exec
by image name. In other words, run commands inside your docker conatiner by image name.
Without this tool you would have to perform a docker ps
first to get a list of running containers, find your container ID, then do something to the effect of docker exec -i -t 7c0410c64a19 npm rebuild
. Only a two step process and not that big of a deal, but somewhat of a pain if you are doing local development and brining up and down containers on the same image.
Install
npm install docker-exec-cli -g
Usage
docker-exec --name <image-name> --cmd="<cmd+args>"
Multiple Containers
The command will be applied to all running containers matching the image name.