1 # Adding nominatim-ui to a nominatim-docker container
3 This document assumes you followed the [nominatim-docker](https://github.com/mediagis/nominatim-docker/) instructions.
5 nominatim-ui is a separate project and it's not planned to add the UI to the nominatim-docker installation.
7 The following instructions might still be useful and/or help further automate such an installation.
10 # Log into the running container
11 docker exec -it nominatim /bin/bash
13 # Download stable nominatim-ui release
14 # available versions: https://github.com/osm-search/nominatim-ui/releases
17 curl -L --fail -o nominatim-ui.tar.gz https://github.com/osm-search/nominatim-ui/releases/download/v${VERSION}/nominatim-ui-${VERSION}.tar.gz
18 tar -xzf nominatim-ui.tar.gz && rm nominatim-ui.tar.gz
19 mv nominatim-ui-$VERSION nominatim-ui
21 # Set the configuration. In this case the UI website should access the API
22 # from the same host and port
23 tee nominatim-ui/dist/theme/config.theme.js << 'EOF'
24 Nominatim_Config.Nominatim_API_Endpoint = '/';
27 # Apache configuration has an entry 'DirectoryIndex search.php'. To make
28 # /ui work we just create such a file. Alternatively change the entry for
30 # Apache configuration is in /etc/apache2/sites-enabled/000-default.conf
31 cd nominatim-ui/dist/ && ln -s index.html search.php && cd -
33 # Move files to Apache webserver directory
34 mkdir /nominatim/website/ui
35 mv nominatim-ui/dist/* /nominatim/website/ui/
37 chown -R nominatim:nominatim /nominatim/website/ui/
40 If the API runs on http://some-host.example.org:8080/ then http://some-host.example.org:8080/ui
41 will now display a website including map and search box.