X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/eacabb0e962cf5301c63622204dd8efa0ce0a7ac..0ee821d64f7fe700e593583f74141e1edafaacc6:/nominatim/clicmd/setup.py diff --git a/nominatim/clicmd/setup.py b/nominatim/clicmd/setup.py index 662bc8ce..056643aa 100644 --- a/nominatim/clicmd/setup.py +++ b/nominatim/clicmd/setup.py @@ -126,10 +126,12 @@ class SetupAll: indexer.index_full(analyse=not args.index_noanalyse) LOG.warning('Post-process tables') - params = ['setup.php', '--create-search-indices', '--create-country-names'] - if args.no_updates: - params.append('--drop') - run_legacy_script(*params, nominatim_env=args, throw_on_fail=not args.ignore_errors) + with connect(args.config.get_libpq_dsn()) as conn: + database_import.create_search_indices(conn, args.config, + args.sqllib_dir, + drop=args.no_updates) + LOG.warning('Create search index for default country names.') + database_import.create_country_names(conn, args.config) webdir = args.project_dir / 'website' LOG.warning('Setup website at %s', webdir)