Forum breadcrumbs - You are here:Tracston Community Forum - DevOps, Micro Services, Cloud, Infrastructure, Development, Monitoring and more...DevOps / Micro Services / Automation: DockerDocker edit file on a not startin …
You need to log in to create posts and topics.
Docker edit file on a not starting/stopped container
moshe@moshe
#1 · 07/08/2022, 2:43 pm
Quote from moshe on 07/08/2022, 2:43 pmProblem
Manual configuration on a docker container and restarting has prevent the container from running
Solution
Copy your file from the container to your local machine
docker ps -a
docker cp ecc23959035e:/etc/my.cnf .
Fix your settings and copy the file back to the container and start it
docker cp ./my.cnf ecc23959035e:/etc/my.cnf
docker start ecc23959035e
Problem
Manual configuration on a docker container and restarting has prevent the container from running
Solution
Copy your file from the container to your local machine
docker ps -a
docker cp ecc23959035e:/etc/my.cnf .
Fix your settings and copy the file back to the container and start it
docker cp ./my.cnf ecc23959035e:/etc/my.cnf
docker start ecc23959035e
Click for thumbs down.0Click for thumbs up.0