rails server + nominatim + renderd server offline

romeo romeo.petruca at perosoft.org
Sun Jan 13 16:28:28 UTC 2019


installed ok:  rails server with opentreetmap OSM, nominatim local, 
renderd server openstreetmap

in browser:

http://localhost:3000 is ok, show the map online

http://localhost/hot/0/0/0.png is ok show world map tile offline

http://localhost/nominatim show dialog box search and blank window map, 
offline

in openstreetmap-website/application.yml changed

   # nominatim_url: "https://nominatim.openstreetmap.org/"
   nominatim_url: "http://localhost/nominatim/"

Now

rails server + nominatim + renderd server working online

offline

rails server + nominatim + renderd server working but showing map from 
browser cache

if i clear cache have no map on screen, but rails server + nominatim 
still working

i believe must changing some js code, found this:

openstreetmap/vendor/assets/openlayers/OpenStreetMap.js

"https://a.tile.openstreetmap.org/${z}/${x}/${y}.png",
"https://b.tile.openstreetmap.org/${z}/${x}/${y}.png",
"https://c.tile.openstreetmap.org/${z}/${x}/${y}.png"
changed to

"http://a.tile.localhost/hot/${z}/${x}/${y}.png",
"http://b.tile.localhost/hot/${z}/${x}/${y}.png",
"http://c.tile.localhost/hot/${z}/${x}/${y}.png"

with no luck, still no map in browser

i must redirect rails server to local tile server renderd, but i don't 
now how

some help ?




On 13.01.2019 14:30, Frederik Ramm wrote:

> Hi,
>
> On 1/13/19 06:11, romeo wrote:
>> All right, is working, access in browser to http://localhost:3000 and
>> the map is there.
>>
>> I have a local openstreetmap of my country local installed ?
>>
>> Disconecting the pc from internet and my map is not working anymore !
>>
>> What i am wrong ?
>>
>> What i must install to have a full local map installed ?
> You have installed a copy of the OSM web site and data base, but not a
> copy of the OSM tile serving tool chain. When you activate the "data
> layer" on your local web site you will see the data from *your* data
> base, but if you look at the tiles you see tiles created by 
> OpenStreetMap.
>
> You need to set up your own tile server, and a replication mechanism
> between your own OSM database (which you already have) and that tile 
> server.
>
> You will end up with two databases that contain the same data, but in
> different formats - the OSM backend database which you already have, and
> the tile server database which is created by osm2pgsql and contains data
> prepared for rendering.
>
> Bye
> Frederik
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20190113/172d92af/attachment.html>


More information about the rails-dev mailing list