Self-hosted 3D Utah trail planning Docker app. Free alternative to Trailforks' paid route planning features, scoped to Utah.
Built on CesiumJS with ESRI satellite imagery and optional self-hosted terrain tiles.
No build step, just open trailforkd.html directly in a browser.
Dockge compose stack:
services:
trailforkd:
container_name: trailforkd
image: ghcr.io/sammothxc/trailforkd
restart: unless-stopped
ports:
- 8080:80
environment:
- CESIUM_ION_TOKEN=${CESIUM_ION_TOKEN}
- TERRAIN_URL=${TERRAIN_URL}
- HEXAGON_URL=${HEXAGON_URL}
- DATABASE_URL=postgres://trailforkd:trailforkd@postgres/trailforkd
networks:
- internal
terrain-server:
container_name: terrain-server
image: nginx:alpine
restart: unless-stopped
volumes:
- ./data/terrain-tiles:/usr/share/nginx/html:ro
networks:
- internal
postgres:
container_name: trailforkd_postgres
image: postgis/postgis:15-3.4-alpine
restart: unless-stopped
environment:
- POSTGRES_DB=trailforkd
- POSTGRES_USER=trailforkd
- POSTGRES_PASSWORD=trailforkd
volumes:
- ./data/postgres-data:/var/lib/postgresql/data
- ./data/initdb:/docker-entrypoint-initdb.d:ro
networks:
- internal
networks:
internal:
volumes:
postgres-data:The terrain-server is only needed once you have terrain tiles generated (see below). Without it, the viewer falls back to a flat ellipsoid.
Terrain tiles are not included — they're generated from UGRC DEM data and can be ~1 GB.
ctb-tile -f Mesh -C -N -o /data/terrain-tiles /data/utah_dem_10m.tif
ctb-tile -f Mesh -C -N -l -o /data/terrain-tiles /data/utah_dem_10m.tif- Point
terrain-serverat the output directory and setTERRAIN_URLin your compose stack.