I setup my Dropbox to sync between my computers so I can ensure I’m always able to pick up where I left off when developing locally, even when work is not yet committed. More importantly, I can very easily roll back changes/deleted files since I use Dropbox’ packrat feature.
Here’s how to get it setup:
- Start with Local setup with the sites on one computer, store the sites you want to share inside a Dropbox folder
- Export each site to blueprints
- Move blueprints from ~/Library/Application Support/Local by Flywheel/blueprints to the other computer
- Install Local on other computer
- Import blueprints but use a different folder outside of the Dropbox folder, this is temporary
- Sites will provision and get setup in Docker
- Now we can change the paths easily enough
- Checkout/clone the Local Add-on repo for Volumes - https://github.com/getflywheel/local-addon-volumes to the ~/Library/Application Support/Local by Flywheel/addons/local-addon-volumes folder
- Enable the add-on ‘Volumes Manager’ then restart Local
- Go into each site that you want to be based in the Dropbox folder and start them
- Go to the More > Volumes section of the site info
- Adjust the directory path easily by changing the values on the left side, then click ‘Remap Volumes’
- Local will provision the updated mappings
- After doing this for all of the sites you want to move/change, edit the ~/Library/Application Support/Local by Flywheel/sites.json file and adjust the ‘path’ strings there too.
Now you’ve got Dropbox shared Local sites, which shares the files and server configs/logs.