forked from hans/Nominatim
Compare commits
2 Commits
master
...
docs-4.5.x
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fc9105d1ea | ||
|
|
76838632d6 |
@@ -127,15 +127,23 @@ you might consider setting:
|
|||||||
and even reduce `autovacuum_work_mem` further. This will reduce the amount
|
and even reduce `autovacuum_work_mem` further. This will reduce the amount
|
||||||
of memory that autovacuum takes away from the import process.
|
of memory that autovacuum takes away from the import process.
|
||||||
|
|
||||||
|
## Installing the latest release
|
||||||
|
|
||||||
|
The latest release can be simply installed via Pypi. Make sure you have
|
||||||
|
osm2pgsql, PostgreSQL and libICU in its development version installed.
|
||||||
|
|
||||||
|
Then just run:
|
||||||
|
|
||||||
|
pip install nominatim-{db,api}
|
||||||
|
|
||||||
## Downloading and building Nominatim
|
## Downloading and building Nominatim
|
||||||
|
|
||||||
### Downloading the latest release
|
The following instructions are only relevant, if you want to build and
|
||||||
|
install Nominatim from source.
|
||||||
|
|
||||||
You can download the [latest release from nominatim.org](https://nominatim.org/downloads/).
|
You can download the [latest release from nominatim.org](https://nominatim.org/downloads/).
|
||||||
The release contains all necessary files. Just unpack it.
|
The release contains all necessary files. Just unpack it.
|
||||||
|
|
||||||
### Downloading the latest development version
|
|
||||||
|
|
||||||
If you want to install latest development version from github, make sure to
|
If you want to install latest development version from github, make sure to
|
||||||
also check out the osm2pgsql subproject:
|
also check out the osm2pgsql subproject:
|
||||||
|
|
||||||
@@ -151,16 +159,16 @@ wget -O Nominatim/data/country_osm_grid.sql.gz https://nominatim.org/data/countr
|
|||||||
|
|
||||||
### Building Nominatim
|
### Building Nominatim
|
||||||
|
|
||||||
#### Building the latest development version with pip
|
#### Building the latest release version with pip
|
||||||
|
|
||||||
Nominatim is easiest to run from its own virtual environment. To create one, run:
|
Nominatim is easiest to run from its own virtual environment. To create one, run:
|
||||||
|
|
||||||
sudo apt-get install virtualenv
|
sudo apt-get install virtualenv
|
||||||
virtualenv /srv/nominatim-venv
|
virtualenv /srv/nominatim-venv
|
||||||
|
|
||||||
To install Nominatim directly from the source tree into the virtual environment, run:
|
To install the latest release of Nominatim into the virtual environment, run:
|
||||||
|
|
||||||
/srv/nominatim-venv/bin/pip install packaging/nominatim-{db,api}
|
/srv/nominatim-venv/bin/pip install nominatim-db nominatim-api
|
||||||
|
|
||||||
#### Building in legacy CMake mode
|
#### Building in legacy CMake mode
|
||||||
|
|
||||||
@@ -168,6 +176,8 @@ To install Nominatim directly from the source tree into the virtual environment,
|
|||||||
Installing Nominatim through CMake is now deprecated. The infrastructure
|
Installing Nominatim through CMake is now deprecated. The infrastructure
|
||||||
will be removed in Nominatim 5.0. Please switch to pip installation.
|
will be removed in Nominatim 5.0. Please switch to pip installation.
|
||||||
|
|
||||||
|
To build Nominatim with CMake, you need to download and unpack the source code
|
||||||
|
as described above.
|
||||||
The code must be built in a separate directory. Create the directory and
|
The code must be built in a separate directory. Create the directory and
|
||||||
change into it.
|
change into it.
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
site_name: Nominatim Manual
|
site_name: Nominatim 4.5.0 Manual
|
||||||
theme:
|
theme:
|
||||||
font: false
|
font: false
|
||||||
name: material
|
name: material
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ export DEBIAN_FRONTEND=noninteractive #DOCS:
|
|||||||
libicu-dev python3-dotenv \
|
libicu-dev python3-dotenv \
|
||||||
python3-pip python3-psutil python3-jinja2 \
|
python3-pip python3-psutil python3-jinja2 \
|
||||||
python3-sqlalchemy python3-asyncpg \
|
python3-sqlalchemy python3-asyncpg \
|
||||||
python3-icu python3-datrie python3-yaml git
|
python3-icu python3-datrie python3-yaml
|
||||||
|
|
||||||
# Some of the Python packages that come with Ubuntu 22.04 are too old,
|
# Some of the Python packages that come with Ubuntu 22.04 are too old,
|
||||||
# so install the latest version from pip:
|
# so install the latest version from pip:
|
||||||
@@ -105,29 +105,22 @@ fi #DOCS:
|
|||||||
# Building and Configuration
|
# Building and Configuration
|
||||||
# --------------------------
|
# --------------------------
|
||||||
#
|
#
|
||||||
# Get the source code from Github and change into the source directory
|
# Get the source code from the Nominatim website and unpack it
|
||||||
#
|
#
|
||||||
if [ "x$1" == "xyes" ]; then #DOCS: :::sh
|
if [ "x$1" == "xyes" ]; then #DOCS: :::sh
|
||||||
cd $USERHOME
|
cd $USERHOME
|
||||||
git clone --recursive https://github.com/openstreetmap/Nominatim.git
|
wget https://nominatim.org/release/Nominatim-4.5.0.tar.bz2
|
||||||
cd Nominatim
|
tar xf Nominatim-4.5.0.tar.bz2
|
||||||
else #DOCS:
|
else #DOCS:
|
||||||
cd $USERHOME/Nominatim #DOCS:
|
cd $USERHOME/Nominatim #DOCS:
|
||||||
fi #DOCS:
|
fi #DOCS:
|
||||||
|
|
||||||
# When installing the latest source from github, you also need to
|
|
||||||
# download the country grid:
|
|
||||||
|
|
||||||
if [ ! -f data/country_osm_grid.sql.gz ]; then #DOCS: :::sh
|
|
||||||
wget -O data/country_osm_grid.sql.gz https://nominatim.org/data/country_grid.sql.gz
|
|
||||||
fi #DOCS:
|
|
||||||
|
|
||||||
# The code must be built in a separate directory. Create this directory,
|
# The code must be built in a separate directory. Create this directory,
|
||||||
# then configure and build Nominatim in there:
|
# then configure and build Nominatim in there:
|
||||||
|
|
||||||
mkdir $USERHOME/build
|
mkdir $USERHOME/build
|
||||||
cd $USERHOME/build
|
cd $USERHOME/build
|
||||||
cmake $USERHOME/Nominatim
|
cmake $USERHOME/Nominatim-4.5.0
|
||||||
make
|
make
|
||||||
sudo make install
|
sudo make install
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ export DEBIAN_FRONTEND=noninteractive #DOCS:
|
|||||||
# Now you can install all packages needed for Nominatim:
|
# Now you can install all packages needed for Nominatim:
|
||||||
|
|
||||||
sudo apt-get install -y osm2pgsql postgresql-postgis postgresql-postgis-scripts \
|
sudo apt-get install -y osm2pgsql postgresql-postgis postgresql-postgis-scripts \
|
||||||
pkg-config libicu-dev virtualenv git
|
pkg-config libicu-dev virtualenv python3-pip
|
||||||
|
|
||||||
|
|
||||||
#
|
#
|
||||||
@@ -94,32 +94,14 @@ fi #DOCS:
|
|||||||
# Building and Configuration
|
# Building and Configuration
|
||||||
# --------------------------
|
# --------------------------
|
||||||
#
|
#
|
||||||
# Get the source code from Github and change into the source directory
|
|
||||||
#
|
|
||||||
if [ "x$1" == "xyes" ]; then #DOCS: :::sh
|
|
||||||
cd $USERHOME
|
|
||||||
git clone https://github.com/openstreetmap/Nominatim.git
|
|
||||||
cd Nominatim
|
|
||||||
else #DOCS:
|
|
||||||
cd $USERHOME/Nominatim #DOCS:
|
|
||||||
fi #DOCS:
|
|
||||||
|
|
||||||
# When installing the latest source from github, you also need to
|
|
||||||
# download the country grid:
|
|
||||||
|
|
||||||
if [ ! -f data/country_osm_grid.sql.gz ]; then #DOCS: :::sh
|
|
||||||
wget -O data/country_osm_grid.sql.gz https://nominatim.org/data/country_grid.sql.gz
|
|
||||||
fi #DOCS:
|
|
||||||
|
|
||||||
# Nominatim should be installed in a separate Python virtual environment.
|
# Nominatim should be installed in a separate Python virtual environment.
|
||||||
# Create the virtual environment:
|
# Create the virtual environment:
|
||||||
|
|
||||||
virtualenv $USERHOME/nominatim-venv
|
virtualenv $USERHOME/nominatim-venv
|
||||||
|
|
||||||
# Now install Nominatim using pip:
|
# Now you can install the lastest version of Nominatim using pip:
|
||||||
|
|
||||||
cd $USERHOME/Nominatim
|
$USERHOME/nominatim-venv/bin/pip install nominatim-db
|
||||||
$USERHOME/nominatim-venv/bin/pip install packaging/nominatim-db
|
|
||||||
|
|
||||||
# Nominatim is now ready to use. The nominatim binary is available at
|
# Nominatim is now ready to use. The nominatim binary is available at
|
||||||
# `$USERHOME/venv/bin/nominatim`. If you want to have 'nominatim' in your
|
# `$USERHOME/venv/bin/nominatim`. If you want to have 'nominatim' in your
|
||||||
@@ -144,8 +126,7 @@ fi #DOCS:
|
|||||||
|
|
||||||
#DOCS:```sh
|
#DOCS:```sh
|
||||||
$USERHOME/nominatim-venv/bin/pip install psycopg[binary] falcon uvicorn gunicorn
|
$USERHOME/nominatim-venv/bin/pip install psycopg[binary] falcon uvicorn gunicorn
|
||||||
cd $USERHOME/Nominatim
|
$USERHOME/nominatim-venv/bin/pip install nominatim-api
|
||||||
$USERHOME/nominatim-venv/bin/pip install packaging/nominatim-api
|
|
||||||
#DOCS:```
|
#DOCS:```
|
||||||
|
|
||||||
# Next you need to create a systemd job that runs Nominatim on gunicorn.
|
# Next you need to create a systemd job that runs Nominatim on gunicorn.
|
||||||
|
|||||||
Reference in New Issue
Block a user