Moving a Local site to a different path


#1

Moving a Local site isn’t super easy, but it’s at least easy to follow these instructions :slight_smile:

Here’s how to move a site to a different path:

  1. Copy the site folder(s) to the new locations you’d like them
  2. 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
  3. Enable the add-on ‘Volumes Manager’ then restart Local
  4. Go into each site that you want to move and start them
  5. Go to the More > Volumes section of the site info
  6. Adjust the directory path easily by changing the values on the left side, then click ‘Remap Volumes’
  7. Local will provision the updated mappings
  8. 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 moved the site location, and you haven’t completely borked your Local config!


Can I move the "Local sites" directory to another Disk/Drive of my PC
#2

Just completed steps 1-7 and both of my sites are working from their new folders. However, I went to complete the final step but it seems that I don’t have a Local by Flywheel folder within Application Support. Does anyone know if and where it has been moved? With the changes and upgrades that have happened recently, is this step still necessary?

Thanks!


#3

I just double checked, the folder is there for me but I don’t know if it recently changed for new installs. Sorry :frowning:


#4

Hi @dgadwa,

Are you on macOS or Windows? If it’s missing on macOS then that’s very odd. :thinking:

If you’re on Windows, you can find Local’s configuration files in %AppData%\Local by Flywheel\


#5

My apologies. I misread the path that sc0ttkclark specified. The correct path is the root of the user folder/Library/Application Support as opposed to the root directory of the drive/Library/Application Support.


#6

Having followed this process on a PC I get stuck at number 6 when browsing for directory…

“Sorry! You must provide a path in /Users”

When I manually update path I get…

“Sorry! There were invalid paths provided. Please ensure that all paths have a valid source and destination. Also, all source paths must begin with either /Users or /Volumes.”

Any ideas on how I can get over this issue?

This is after having issues where it failed to start local machine and most recently “Error! Container is missing.”

Im starting to wish i hand jumped from XAMP! :frowning:


#7

@sc0ttkclark Thank you for the steps. Just curious though wouldn’t export and re-import be a bit easier than this? Is there a reason you opted not to do that?


#8

@mansabadman,

The Volumes add-on is currently incompatible with Windows.

Can you try exporting then re-importing like @jb510 mentioned?


#9

Hi Clay,

How will that fix the issue?

Surely the export will export the path info too? and then when it’s reimported it will have the same path?


#10

It is worth to mention that each directory path has a different end, which met the end of the container destination.

for instance:
~/path/WP_folder/log/mysql if the container destination reads /var/log/mysql.


#11

When you re-import the site you can change the name, domain, path, as well as the environment settings.


#12

Thank you. Worked for me!

Just an update on step 6: the site needs to be started to bring up the ‘Remap Volumes’ button.


#13

Yes this worked for me but having to go through this process for no reason was a real ball ache. So much so that on top of this issue and the SSL issue it made more sense to go back to WAMP.


#14

Many thanks for this walkthrough