How can I run a docker exec command inside a docker container

416    Asked by bruce_8968 in Salesforce , Asked on Jul 24, 2021

When I try to run the following command I get an error :

docker exec -i nullmailer sendmail -f user@yahoo.com

This shows the following error:

the docker command does not exist


Answered by Bruce Benedict

you can run any command to solve docker exec bash in a running container just knowing its ID (or name):

  docker exec -it  echo "I'm inside the container!"

Note:The container needs to be running.



Your Answer

Interviews

Parent Categories