Prerequisites

If using Martin with PostgreSQL database, you must install PostGIS with at least v3.0+. Postgis v3.1+ is recommended.

Docker

Martin is also available as a Docker image. You could either share a configuration file from the host with the container via the -v param, or you can let Martin auto-discover all sources e.g. by passing DATABASE_URL or specifying the .mbtiles/.pmtiles files or URLs to .pmtiles.

export PGPASSWORD=postgres  # secret!

docker run -p 3000:3000 \
           -e PGPASSWORD \
           -e DATABASE_URL=postgresql://user@host:port/db \
           -v /path/to/config/dir:/config \
           ghcr.io/maplibre/martin --config /config/config.yaml

From Binary Distributions Manually

You can download martin from GitHub releases page.

Platformx64ARM-64
Linux.tar.gz (gnu)
.tar.gz (musl)
.deb
.tar.gz (musl)
macOS.tar.gz.tar.gz
Windows.zip

Rust users can install pre-built martin binary with cargo-binstall and cargo.

cargo install cargo-binstall
cargo binstall martin
martin --help

From package

To install with apt source and others, We need your help to improve packaging for various platforms.

Homebrew

If you are using macOS and Homebrew you can install martin using Homebrew tap.

brew tap maplibre/martin
brew install martin
martin --help

Debian Packages(x86_64) manually

curl -O https://github.com/maplibre/martin/releases/latest/download/martin-Debian-x86_64.deb
sudo dpkg -i ./martin-Debian-x86_64.deb
martin --help
rm ./martin-Debian-x86_64.deb

Building From source

If you install Rust, you can build martin from source with Cargo:

cargo install martin --locked
martin --help