Problem/Motivation

When sites are migrated, the file paths are not updated in the drushrc alias file.

Steps to reproduce

  • Create a site, such as site1.example.org
  • Migrate it to site2.example.org

Then grep for "file" in the `~/.drush/site2.example.org.alias.drushrc.php`. It will display the old URLs.

Verify does not fix this issue, unless we first manually edit the drushrc file.

Comments

bgm created an issue. See original summary.

kienan’s picture

I was able to reproduce this in 7.x-3.190 both 7.x-3.191 ("testing" - 2020.12.04)

bgm’s picture

I only had a quick look, but found that the drush alias file is rewritten here:

* file: platform/migrate.provision.inc
* function: drush_provision_drupal_post_provision_migrate

I don't know whether "d()->write_alias();" gets called from there (if rename) or from import.

bgm’s picture

Project: Provision » Hostmaster (Aegir)
agaq’s picture

I reproduced it in 7.x-3.190 (on Ubuntu 18.04, with debian package version 3.190)

I migrated a site 'site.example.com' to 'migrated-site.example.com'.

The migrated site did not display inline images.

`~/.drush/migrated-site.example.org.alias.drushrc.php` still showed the old file paths:

'file_public_path' => 'sites/site.example.com/files',
'file_private_path' => 'sites/site.example.com/private/files',
'file_temporary_path' => 'sites/site.example.com/private/temp',

I updated the paths with new URL:

'file_public_path' => 'sites/migrated-site.example.com/files',
'file_private_path' => 'sites/migrated-site.example.com/private/files',
'file_temporary_path' => 'sites/migrated-site.example.com/private/temp',

Then re-verified the migrated site.

The inline images reappeared.

helmo’s picture

Status: Active » Needs review

Please try with the new 3.19.2 release as that might fix it.