I use drush site aliases and
drush sql-sync as part of my daily workflow between my local development environment and my company's production/staging servers (Acquia dev cloud). This works great for single site instances, but I haven't been able to get it to work with multisites.
Example site structure for my @remote alias:
- default.com ``drush @remote`` <-- commands not targeted with `-l` execute here
- sitename.com ``drush @remote -l sitename.com status``
- foobar.com ``drush @remote -l foobar.com sql-connect``
For other drush commands, I can target the multisite that I want use the
-l switch to specify a particular multisite, and I get the correct output for
drush status and
drush sql-connect (correct
However, when I try to use
-l with drush sql-sync, it just targets the root site, no matter what. I can get around this by manually dumping the database and doing
drush sql-cli @remote -l multisite.com < db.sql, but it's not half as quick as just doing
drush sql-sync @local -l sitename.com @drush.remote -l sitename.com
I can open up a drush issue queue if this is a bug, but I'm wanted to check and see if I was doing something wrong first. Thanks!