I’m working with two different PCs in the same project. So sometimes I can commit a change from one PC and another time I can commit a change from another PC. In case the changes are involving the code, it’s not really a problem thanks to git; but what about the database?
The project uses docker (docker-compose) to spin up several services, among them I have a MySQL server. What I’d like to do, is dumping the latest version of the DB before the command
docker-composer stop complete all the actions.
Is there a way I can inject the
mysqldump [...] command when the
docker-composer stop is running?
Any alternatives, just in case?