Easy way to change map to another city?

Hi, I wanted to use OpenRemote with the map of Berlin city. Is there an easy way to change this?

I downloaded the map already from Planet OpenStreetMap Tiles, GeoData and OpenData Maps | MapTiler Data. Afterwards I am lost, when I follow the steps in here: User Guide: Custom deployment · openremote/openremote Wiki · GitHub
When I try to execute the command git submodule update --rebase --remote of step 2 it always says that the permission is denied (publickey) and it could not read from the remote repository.

Does someone has an idea how to solve this issue? I have an SSH key in my Github repo.

Hi @deputy-chief-hardy,

welcome to the forum.

in the folder, where your docker-compose.yml file is stored you have to create some subfolders:
./deployment/map/

there you store the mapdata.mbtiles and create mapsettings.json based on:

in the mapsettings.json you can customize your bounds and where the map is centered at opening.

bound tool: OSM - Tile Calculator

don’t forget to swap the longtitude and latitude in mapsettings.json too.
"center": [ longitude, latitude],

let us know, if you get stuck or you achieved it :slight_smile:

1 Like

Hi Denis,
thanks for your welcoming words and your quick answer. I followed all the steps you are describing. And afterwards I just have to run these two commands?

    docker-compose pull
    docker-compose -p openremote up

If yes, I missed something else because it still shows me the map of Rotterdam unfortunately when I go to https://localhost/manager/

Hm did you add in docker-compose.yml:

- ./deployment:/deployment

Under:

volumes:
- temp-data:/tmp 

You mean under manager @Denis? Now I did. Doesn’t change anything …

Here is my docker-compose.yml:

> # OpenRemote v3
> #
> # Profile that runs the stack by default on https://localhost using a self-signed SSL certificate,
> # but optionally on https://$OR_HOSTNAME with an auto generated SSL certificate from Letsencrypt.
> #
> # It is configured to use the AWS logging driver.
> #
> version: '2.4'
> 
> volumes:
>   proxy-data:
>   temp-data:
>   postgresql-data:
> #  btmesh-data:
> 
> services:
> 
>   proxy:
>     image: openremote/proxy:${PROXY_VERSION:-latest}
>     restart: always
>     depends_on:
>       manager:
>         condition: service_healthy
>     ports:
>       - "80:80"
>       - "${OR_SSL_PORT:-443}:443"
>       - "8883:8883"
>     volumes:
>       - proxy-data:/deployment
>     environment:
>       LE_EMAIL: ${OR_EMAIL_ADMIN:-}
>       DOMAINNAME: ${OR_HOSTNAME:-localhost}
>       DOMAINNAMES: ${OR_ADDITIONAL_HOSTNAMES:-}
>       # USE A CUSTOM PROXY CONFIG - COPY FROM https://raw.githubusercontent.com/openremote/proxy/main/haproxy.cfg
>       #HAPROXY_CONFIG: '/data/proxy/haproxy.cfg'
> 
>   postgresql:
>     restart: always
>     image: openremote/postgresql:${POSTGRESQL_VERSION:-latest}
>     volumes:
>       - postgresql-data:/var/lib/postgresql/data
>       - temp-data:/tmp
> 
>   keycloak:
>     restart: always
>     image: openremote/keycloak:${KEYCLOAK_VERSION:-latest}
>     depends_on:
>       postgresql:
>         condition: service_healthy
>     volumes:
>       - ./deployment:/deployment
>     environment:
>       KEYCLOAK_ADMIN_PASSWORD: ${OR_ADMIN_PASSWORD:-secret}
>       KC_HOSTNAME: ${OR_HOSTNAME:-localhost}
>       KC_HOSTNAME_PORT: ${OR_SSL_PORT:--1}
> 
> 
>   manager:
> #    privileged: true
>     restart: always
>     image: openremote/manager:${MANAGER_VERSION:-latest}
>     depends_on:
>       keycloak:
>         condition: service_healthy
>     environment:
>       OR_SETUP_TYPE:
>       OR_ADMIN_PASSWORD:
>       OR_SETUP_RUN_ON_RESTART:
>       OR_EMAIL_HOST:
>       OR_EMAIL_USER:
>       OR_EMAIL_PASSWORD:
>       OR_EMAIL_X_HEADERS:
>       OR_EMAIL_FROM:
>       OR_EMAIL_ADMIN:
>       OR_HOSTNAME: ${OR_HOSTNAME:-localhost}
>       OR_ADDITIONAL_HOSTNAMES: ${OR_ADDITIONAL_HOSTNAMES:-}
>       OR_SSL_PORT: ${OR_SSL_PORT:--1}
>       OR_DEV_MODE: ${OR_DEV_MODE:-false}
> 
>       # The following variables will configure the demo
>       OR_FORECAST_SOLAR_API_KEY:
>       OR_OPEN_WEATHER_API_APP_ID:
>       OR_SETUP_IMPORT_DEMO_AGENT_KNX:
>       OR_SETUP_IMPORT_DEMO_AGENT_VELBUS:
>     volumes:
>       - temp-data:/tmp
>       - ./deployment:/deployment
> #      - /var/run/dbus:/var/run/dbus
> #      # Bluetooth mesh volume
> #      - btmesh-data:/btmesh
> #   devices:
> #     - /dev/ttyACM0:/dev/ttyS0

You can follow this:

Thanks @raotanmay97 . It seems that the video is based on an older version. The current steps differ from the steps described on Github …

The same steps works for me though I have deployment for my city using the same steps.

Did you put the .mbtiles and mapsettings.json in /deployment/map? Remember that coordinates format is W,S,E,N
Also after every change I do docker-compose down and up

Yes I did, but I get an empty page …

I was watching the video now for the third time, but it does not work. I followed it step by step and everything works till I open the localhost and there is an empty page:

It doesn’t even show the search bar and the zoom. Please show us everything you did about the map, maybe there is a small error somewhere

So this is my directory structure:

C:.
│   docker-compose.yml
│
└───deployment
    │   openremote.log.0
    │
    ├───manager
    │   │   keycloak.json
    │   │
    │   └───app
    │       │   manager_config.json
    │       │
    │       └───images
    └───map
            mapdata.mbtiles
            mapsettings.json

This is my docker-compose.yml:

# OpenRemote v3
#
# Profile that runs the stack by default on https://localhost using a self-signed SSL certificate,
# but optionally on https://$OR_HOSTNAME with an auto generated SSL certificate from Letsencrypt.
#
# It is configured to use the AWS logging driver.
#
version: '2.4'

volumes:
  proxy-data:
  temp-data:
  postgresql-data:
#  btmesh-data:

services:

  proxy:
    image: openremote/proxy:${PROXY_VERSION:-latest}
    restart: always
    depends_on:
      manager:
        condition: service_healthy
    ports:
      - "80:80"
      - "${OR_SSL_PORT:-443}:443"
      - "8883:8883"
    volumes:
      - proxy-data:/deployment
    environment:
      LE_EMAIL: ${OR_EMAIL_ADMIN:-}
      DOMAINNAME: ${OR_HOSTNAME:-localhost}
      DOMAINNAMES: ${OR_ADDITIONAL_HOSTNAMES:-}
      # USE A CUSTOM PROXY CONFIG - COPY FROM https://raw.githubusercontent.com/openremote/proxy/main/haproxy.cfg
      #HAPROXY_CONFIG: '/data/proxy/haproxy.cfg'

  postgresql:
    restart: always
    image: openremote/postgresql:${POSTGRESQL_VERSION:-latest}
    volumes:
      - postgresql-data:/var/lib/postgresql/data
      - temp-data:/tmp

  keycloak:
    restart: always
    image: openremote/keycloak:${KEYCLOAK_VERSION:-latest}
    depends_on:
      postgresql:
        condition: service_healthy
    volumes:
      - ./deployment:/deployment
    environment:
      KEYCLOAK_ADMIN_PASSWORD: ${OR_ADMIN_PASSWORD:-secret}
      KC_HOSTNAME: ${OR_HOSTNAME:-localhost}
      KC_HOSTNAME_PORT: ${OR_SSL_PORT:--1}


  manager:
#    privileged: true
    restart: always
    image: openremote/manager:${MANAGER_VERSION:-latest}
    depends_on:
      keycloak:
        condition: service_healthy
    environment:
      OR_SETUP_TYPE:
      OR_ADMIN_PASSWORD:
      OR_SETUP_RUN_ON_RESTART:
      OR_EMAIL_HOST:
      OR_EMAIL_USER:
      OR_EMAIL_PASSWORD:
      OR_EMAIL_X_HEADERS:
      OR_EMAIL_FROM:
      OR_EMAIL_ADMIN:
      OR_HOSTNAME: ${OR_HOSTNAME:-localhost}
      OR_ADDITIONAL_HOSTNAMES: ${OR_ADDITIONAL_HOSTNAMES:-}
      OR_SSL_PORT: ${OR_SSL_PORT:--1}
      OR_DEV_MODE: ${OR_DEV_MODE:-false}

      # The following variables will configure the demo
      OR_FORECAST_SOLAR_API_KEY:
      OR_OPEN_WEATHER_API_APP_ID:
      OR_SETUP_IMPORT_DEMO_AGENT_KNX:
      OR_SETUP_IMPORT_DEMO_AGENT_VELBUS:
    volumes:
      - ./deployment:/deployment
      - temp-data:/tmp
#      - /var/run/dbus:/var/run/dbus
#      # Bluetooth mesh volume
#      - btmesh-data:/btmesh
#   devices:
#     - /dev/ttyACM0:/dev/ttyS0

And my mapsettings.json:
(the coordinates are of the city of Karlsruhe, i downloaded the map from Planet OpenStreetMap Tiles, GeoData and OpenData Maps | MapTiler Data)

{
  "options": {
    "default": {
      "center": [ 8.4, 49.0 ],
      "bounds": [ 8.27, 48.94, 8.55, 49.1 ],
      "zoom": 14,
      "maxZoom": 19,
      "boxZoom": false,
      "geocodeUrl": "https://nominatim.openstreetmap.org"
    }
  },
  "version": 8,
  "sources": {
    "vector_tiles": {
      "type": "vector",
      "url": "mbtiles://mapdata.mbtiles"
    }
  },
  "sprite": "map/sprites/bright-v9",
  "glyphs": "{fontstack}/{range}.pbf",
  "layers": [
    {
      "id": "background",
      "type": "background",
      "paint": {
        "background-color": "#ecf2ea"
      }
    },
    {
      "id": "landcover-glacier",
      "type": "fill",
      "metadata": {
        "mapbox:group": "1444849388993.3071"
      },
      "source": "vector_tiles",
      "source-layer": "landcover",
      "filter": [
        "==",
        "subclass",
        "glacier"
      ],
      "layout": {
        "visibility": "visible"
      },
      "paint": {
        "fill-color": "#fff",
        "fill-opacity": {
          "base": 1,
          "stops": [
            [ 0, 0.9 ],
            [ 10, 0.3 ]
          ]
        }
      }
    },

   ...

Coordinates seem correct, it should work like this.
The only thing i noticed is that you swapped the volumes in the .yml…but don’t really think this change anything?

volumes:
  - temp-data:/tmp
  - ./deployment:/deployment

Hi @pcr, thanks for your answer! No, unfortunately it does not change anything, I tried it already …
You are of the openremote team right? Is it maybe possible to get a short video call with you, so that I can show you how I did things? We are thinking of using the platform in the company, but if I can not change the map, it will not be usable for us. :frowning:

Hi @deputy-chief-hardy, no I’m just a regular user, I’m sorry
Probably one of them will be more helpful, the only thing that I can think of is try another instance. Maybe there is something not working in that one

Hi @pcr, thats a good hint, thanks. I will try it at home again with another device.

The business device was the problem. With my private device it worked now!

2 Likes