I’m a comparative newbie to Docker, and have hit an issue I can’t find online help for.
We’re running Docker version 18.09.6, build 481bc77 inside an AWS EC2 instance (M3.Large).
One container is running MySQL Community Server 5.6.44 in a configuration that doesn’t include general MySQL logging. I want to change the MySQL config file to check that I can get logging going, and then eventually, change the image with a change to that single config file. It’s easy to make the config file edits once I install vim in the container, but when I use ‘service mysql restart’, the entire container stops or crashes immediately, and (as expected) on restart, the config file change is gone.
When I use ’ service mysql status’, it returns…
[info] MySQL Community Server 5.6.44 is running.
which tells me that the ‘service’ command works, at least partially.
Using ‘service mysql stop’ also crashes/stops the container
Is this expected behaviour? If so, how do i set it up so I can experiment with configuration options without building a new container for each one - or how do I make short-term changes for experiments on a running container if the ‘service’ command stops it?