mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-03-07 18:44:07 +00:00
also adapt indexing command in update script
This commit is contained in:
@@ -81,6 +81,8 @@ if (!is_null(CONST_Osm2pgsql_Flatnode_File) && CONST_Osm2pgsql_Flatnode_File) {
|
|||||||
$sOsm2pgsqlCmd .= ' --flat-nodes '.CONST_Osm2pgsql_Flatnode_File;
|
$sOsm2pgsqlCmd .= ' --flat-nodes '.CONST_Osm2pgsql_Flatnode_File;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$sIndexCmd = CONST_BasePath.'/nominatim/nominatim.py';
|
||||||
|
|
||||||
if ($aResult['init-updates']) {
|
if ($aResult['init-updates']) {
|
||||||
// sanity check that the replication URL is correct
|
// sanity check that the replication URL is correct
|
||||||
$sBaseState = file_get_contents(CONST_Replication_Url.'/state.txt');
|
$sBaseState = file_get_contents(CONST_Replication_Url.'/state.txt');
|
||||||
@@ -302,7 +304,11 @@ if ($aResult['recompute-word-counts']) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ($aResult['index']) {
|
if ($aResult['index']) {
|
||||||
$sCmd = CONST_InstallPath.'/nominatim/nominatim -i -d '.$aDSNInfo['database'].' -P '.$aDSNInfo['port'].' -t '.$aResult['index-instances'].' -r '.$aResult['index-rank'];
|
$sCmd = $sIndexCmd
|
||||||
|
.' -d '.$aDSNInfo['database']
|
||||||
|
.' -P '.$aDSNInfo['port']
|
||||||
|
.' -t '.$aResult['index-instances']
|
||||||
|
.' -r '.$aResult['index-rank'];
|
||||||
if (isset($aDSNInfo['hostspec']) && $aDSNInfo['hostspec']) {
|
if (isset($aDSNInfo['hostspec']) && $aDSNInfo['hostspec']) {
|
||||||
$sCmd .= ' -H ' . $aDSNInfo['hostspec'];
|
$sCmd .= ' -H ' . $aDSNInfo['hostspec'];
|
||||||
}
|
}
|
||||||
@@ -348,7 +354,10 @@ if ($aResult['import-osmosis'] || $aResult['import-osmosis-all']) {
|
|||||||
$sImportFile = CONST_InstallPath.'/osmosischange.osc';
|
$sImportFile = CONST_InstallPath.'/osmosischange.osc';
|
||||||
$sCMDDownload = CONST_Pyosmium_Binary.' --server '.CONST_Replication_Url.' -o '.$sImportFile.' -s '.CONST_Replication_Max_Diff_size;
|
$sCMDDownload = CONST_Pyosmium_Binary.' --server '.CONST_Replication_Url.' -o '.$sImportFile.' -s '.CONST_Replication_Max_Diff_size;
|
||||||
$sCMDImport = $sOsm2pgsqlCmd.' '.$sImportFile;
|
$sCMDImport = $sOsm2pgsqlCmd.' '.$sImportFile;
|
||||||
$sCMDIndex = CONST_InstallPath.'/nominatim/nominatim -i -d '.$aDSNInfo['database'].' -P '.$aDSNInfo['port'].' -t '.$aResult['index-instances'];
|
$sCMDIndex = $sIndexCmd
|
||||||
|
.' -d '.$aDSNInfo['database']
|
||||||
|
.' -P '.$aDSNInfo['port']
|
||||||
|
.' -t '.$aResult['index-instances'];
|
||||||
if (isset($aDSNInfo['hostspec']) && $aDSNInfo['hostspec']) {
|
if (isset($aDSNInfo['hostspec']) && $aDSNInfo['hostspec']) {
|
||||||
$sCMDIndex .= ' -H ' . $aDSNInfo['hostspec'];
|
$sCMDIndex .= ' -H ' . $aDSNInfo['hostspec'];
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user