Installation
nimap ships as a single Docker image that serves both the web application and the API. It stores its data in PostgreSQL with PostGIS and keeps uploaded files in a directory on disk.
Requirements
Section titled “Requirements”- Docker with the Compose plugin (
docker compose). - PostgreSQL 18 with PostGIS. Version 18 is a hard minimum, older versions will not work. The Compose file below starts a suitable database for you.
- HTTPS in front of nimap for production use. See
SERVICE_ENV.
Installation
Section titled “Installation”-
Create a directory for the installation and a
.envfile with a database password. Docker Compose reads.envautomatically.Terminal window mkdir nimap && cd nimapecho "DB_PASSWORD=$(openssl rand -hex 24)" > .envThe password is also used inside a connection URL, so stick to letters and digits.
-
Create
compose.yaml:compose.yaml services:db:image: postgis/postgis:18-3.6-alpinerestart: unless-stoppedenvironment:POSTGRES_USER: nimapPOSTGRES_PASSWORD: ${DB_PASSWORD:?set DB_PASSWORD in .env}POSTGRES_DB: nimapvolumes:- db-data:/var/lib/postgresql/18/dockerhealthcheck:test: ["CMD-SHELL", "pg_isready -U nimap -d nimap"]interval: 5stimeout: 5sretries: 10nimap:image: ghcr.io/nimap-dev/nimap:mainrestart: unless-stoppedenvironment:SERVICE_ENV: productionSERVICE_PORT: 8080SERVICE_DATABASE_URL: postgres://nimap:${DB_PASSWORD}@db:5432/nimap?sslmode=disableSERVICE_MEDIA_DIR: /data/mediaSERVICE_LOG_LEVEL: infoSERVICE_LOG_FORMAT: jsonSERVICE_AUTO_MIGRATE: trueports:- "8080:8080"volumes:- media:/data/mediahealthcheck:test: ["CMD", "wget", "-qO-", "http://localhost:8080/healthz"]interval: 10stimeout: 3sretries: 5depends_on:db:condition: service_healthyvolumes:db-data:media:The database is reachable only from the nimap container. Its data lives in the
db-datavolume, uploaded files in themediavolume. Back up both together. All settings are described in Configuration. -
Start nimap:
Terminal window docker compose up -dOn the first start nimap creates the database schema. Check that both containers are
healthy:Terminal window docker compose psIf the
nimapcontainer keeps restarting, its log says why:Terminal window docker compose logs nimap -
Create the first administrator. The command asks for the password, which must be at least 8 characters long.
Terminal window docker compose exec nimap /nimap new-user --username admin --email admin@example.com --role adminFurther accounts can be created in the application by the administrator.
-
Open nimap in the browser and sign in with the new account.