mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-02-14 18:37:58 +00:00
Compare commits
4 Commits
v4.3.1
...
docs-4.3.x
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f69890c86f | ||
|
|
7ab73f5698 | ||
|
|
a2b89309ff | ||
|
|
0a892133af |
@@ -43,6 +43,22 @@ virtualenv /srv/nominatim-venv
|
||||
Next you need to set up the service that runs the Nominatim frontend. This is
|
||||
easiest done with a systemd job.
|
||||
|
||||
First you need to tell systemd to create a socket file to be used by
|
||||
hunicorn. Crate the following file `/etc/systemd/system/nominatim.socket`:
|
||||
|
||||
``` systemd
|
||||
[Unit]
|
||||
Description=Gunicorn socket for Nominatim
|
||||
|
||||
[Socket]
|
||||
ListenStream=/run/nominatim.sock
|
||||
SocketUser=www-data
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
```
|
||||
|
||||
Now you can add the systemd service for Nominatim itself.
|
||||
Create the following file `/etc/systemd/system/nominatim.service`:
|
||||
|
||||
``` systemd
|
||||
@@ -74,12 +90,14 @@ its own Python process using
|
||||
[`NOMINATIM_API_POOL_SIZE`](../customize/Settings.md#nominatim_api_pool_size)
|
||||
connections to the database to serve requests in parallel.
|
||||
|
||||
Make the new service known to systemd and start it:
|
||||
Make the new services known to systemd and start it:
|
||||
|
||||
``` sh
|
||||
sudo systemctl daemon-reload
|
||||
sudo systemctl enable nominatim
|
||||
sudo systemctl start nominatim
|
||||
sudo systemctl enable nominatim.socket
|
||||
sudo systemctl start nominatim.socket
|
||||
sudo systemctl enable nominatim.service
|
||||
sudo systemctl start nominatim.service
|
||||
```
|
||||
|
||||
This sets the service up, so that Nominatim is automatically started
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
site_name: Nominatim Manual
|
||||
site_name: Nominatim 4.3.2 Manual
|
||||
theme:
|
||||
name: material
|
||||
features:
|
||||
|
||||
@@ -27,7 +27,7 @@ export DEBIAN_FRONTEND=noninteractive #DOCS:
|
||||
postgresql-contrib-12 postgresql-12-postgis-3-scripts \
|
||||
php-cli php-pgsql php-intl libicu-dev python3-dotenv \
|
||||
python3-psycopg2 python3-psutil python3-jinja2 python3-pip \
|
||||
python3-icu python3-datrie python3-yaml git
|
||||
python3-icu python3-datrie python3-yaml
|
||||
|
||||
# Some of the Python packages that come with Ubuntu 20.04 are too old, so
|
||||
# install the latest version from pip:
|
||||
@@ -109,25 +109,18 @@ fi #DOCS:
|
||||
#
|
||||
if [ "x$1" == "xyes" ]; then #DOCS: :::sh
|
||||
cd $USERHOME
|
||||
git clone --recursive https://github.com/openstreetmap/Nominatim.git
|
||||
cd Nominatim
|
||||
wget https://nominatim.org/release/Nominatim-4.3.2.tar.bz2
|
||||
tar xf Nominatim-4.3.2.tar.bz2
|
||||
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:
|
||||
|
||||
# The code must be built in a separate directory. Create this directory,
|
||||
# then configure and build Nominatim in there:
|
||||
|
||||
mkdir $USERHOME/build
|
||||
cd $USERHOME/build
|
||||
cmake $USERHOME/Nominatim
|
||||
cmake $USERHOME/Nominatim-4.3.2
|
||||
make
|
||||
sudo make install
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ export DEBIAN_FRONTEND=noninteractive #DOCS:
|
||||
php-cli php-pgsql php-intl libicu-dev python3-dotenv \
|
||||
python3-psycopg2 python3-psutil python3-jinja2 \
|
||||
python3-icu python3-datrie python3-sqlalchemy \
|
||||
python3-asyncpg python3-yaml git
|
||||
python3-asyncpg python3-yaml
|
||||
|
||||
#
|
||||
# System Configuration
|
||||
@@ -104,25 +104,18 @@ fi #DOCS:
|
||||
#
|
||||
if [ "x$1" == "xyes" ]; then #DOCS: :::sh
|
||||
cd $USERHOME
|
||||
git clone --recursive https://github.com/openstreetmap/Nominatim.git
|
||||
cd Nominatim
|
||||
wget https://nominatim.org/release/Nominatim-4.3.2.tar.bz2
|
||||
tar xf Nominatim-4.3.2.tar.bz2
|
||||
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:
|
||||
|
||||
# The code must be built in a separate directory. Create this directory,
|
||||
# then configure and build Nominatim in there:
|
||||
|
||||
mkdir $USERHOME/build
|
||||
cd $USERHOME/build
|
||||
cmake $USERHOME/Nominatim
|
||||
cmake $USERHOME/Nominatim-4.3.2
|
||||
make
|
||||
sudo make install
|
||||
|
||||
|
||||
Reference in New Issue
Block a user