brew install havoc-io/mutagen/mutagen
https://mutagen.io/documentation/installation/- Include
mutagen daemon start
into ~/.bashrc (others maybe .zshrc etc, or manually run prior use) - In docker-compose.yml, remove shared volumes (remember paths for
mutagen create
) - Create first setup shell script for team each paths would add command like this:
mutagen create [path-to-host] docker://$(docker-compose ps -q [service-name])/[container-target-path] \
--default-owner-beta=[default-app-owner-eg-www-data] \
--ignore-vcs \
--sync-mode=two-way-resolved
First time usage:
docker-compose up -d
bash ./setup-codesync.sh
Later usage: Just make sure mutagen daemon start
and docker-compose up -d
are working properly.
Note: You can check sync states from each sessions with mutagen list
and also cleanup by mutagen terminate --all
and start over