Run script from host machine on Docker container with exec [closed]
I do have docker container running and I do quite complex script to run inside container.
The script is located on host machine.
I can’t modify Dockerfile
How can I place script file to docker vm to run it with docker exec?
One Solution collect form web for “Run script from host machine on Docker container with exec [closed]”
docker cp your script, and then you run it, with something like
docker exec -it container_id script
You can see some examples at
docker exec -it container_id unzip -d ~/Captvty ~/Téléchargements/captvty-2.3.10.zip
answer Yes to All
docker exec -it container_id rm ~/Téléchargements/captvty-2.3.10.zip