Skip to content

Commit

Permalink
Get drush command fto dump sql from configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
stmh committed Sep 1, 2019
1 parent 728dc1b commit 0667ed1
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/Method/DrushMethod.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,8 @@ public function getDefaultConfig(ConfigurationService $configuration_service, ar
$config['drushVersion'] = in_array('drush9', $host_config['needs'])
? 9
: $configuration_service->getSetting('drushVersion', 8);


$config['sqlDumpCommand'] = 'sql-dump';
$config['supportsZippedBackups'] = true;
$config['siteFolder'] = '/sites/default';
$config['filesFolder'] = '/sites/default/files';
Expand Down Expand Up @@ -386,8 +387,9 @@ protected function backupSQL(
$shell->run(sprintf('rm -f %s', $backup_file_name));
$return = $backup_file_name;
}

$this->runDrush($shell, 'sql-dump %s --result-file=%s', $dump_options, $backup_file_name);

$sql_dump_cmd = $host_config->get('sqlDumpCommand', 'sql-dump');
$this->runDrush($shell, '%s %s --result-file=%s', $sql_dump_cmd, $dump_options, $backup_file_name);
return $return;
}

Expand Down

0 comments on commit 0667ed1

Please sign in to comment.