Re: [Talk-GB] OSM augmented reality project - affordable hosting recommendations or Overpass?

2019-02-05 Thread Nick Whitelegg

Hello everyone,


Thanks for the suggestions. I've had an offer of hosting (many thanks!) but 
it's good to know what options are available.

Roland - thanks for the info on Overpass. Am aware that GeoJSON isn't supposed 
to be epsg:3857 but I do it that way as it saves a reprojection stage.


Thank,s

Nick



From: Roland Olbricht 
Sent: 05 February 2019 16:59:48
To: Nick Whitelegg; d...@openstreetmap.org; talk-gb@openstreetmap.org
Subject: Re: [Talk-GB] OSM augmented reality project - affordable hosting 
recommendations or Overpass?

Hi,

> As an alternative, I was wondering how acceptable it would be to use the
> Overpass API to obtain the data? Downloaded data would be cached on the
> device so for a given area, data would only need to be downloaded once.

I'm fine with such a usage. The fine print is about other issues:

- Overpass API does support GeoJSON indirectly, but GeoJSON does not
support EPSG:3857, see
https://tools.ietf.org/html/rfc7946#section-4

To get GeoJSON I suggest

[out:json];
way(south,west,north,east)[highway];
convert link ::=::,::geom=geom();
out geom;

where (south,west,north,east) is the bounding box.

As an act of courtesy I suggest to set the "Accept-Encoding: deflate,
gzip" header and use

[out:json];
way(south,west,north,east)[highway];
if (count(ways) < 2)
{
   convert link ::=::,::geom=geom();
   out geom;
}
else
{
   make error what="Too many ways in this bounding box";
   out;
}

This compresses the data and bails out if there are more than 2 ways
in the bounding box, corresponding to between 1 MB and 2 MB of data.
Overpass would happily deliver about 1 GB per user and day, but the
users may have data plans with rather 1 GB per month.

Thanks,
Roland
___
Talk-GB mailing list
Talk-GB@openstreetmap.org
https://lists.openstreetmap.org/listinfo/talk-gb


Re: [Talk-GB] OSM augmented reality project - affordable hosting recommendations or Overpass?

2019-02-05 Thread Roland Olbricht

Hi,

As an alternative, I was wondering how acceptable it would be to use the 
Overpass API to obtain the data? Downloaded data would be cached on the 
device so for a given area, data would only need to be downloaded once.


I'm fine with such a usage. The fine print is about other issues:

- Overpass API does support GeoJSON indirectly, but GeoJSON does not 
support EPSG:3857, see

https://tools.ietf.org/html/rfc7946#section-4

To get GeoJSON I suggest

[out:json];
way(south,west,north,east)[highway];
convert link ::=::,::geom=geom();
out geom;

where (south,west,north,east) is the bounding box.

As an act of courtesy I suggest to set the "Accept-Encoding: deflate, 
gzip" header and use


[out:json];
way(south,west,north,east)[highway];
if (count(ways) < 2)
{
  convert link ::=::,::geom=geom();
  out geom;
}
else
{
  make error what="Too many ways in this bounding box";
  out;
}

This compresses the data and bails out if there are more than 2 ways 
in the bounding box, corresponding to between 1 MB and 2 MB of data. 
Overpass would happily deliver about 1 GB per user and day, but the 
users may have data plans with rather 1 GB per month.


Thanks,
Roland

___
Talk-GB mailing list
Talk-GB@openstreetmap.org
https://lists.openstreetmap.org/listinfo/talk-gb


Re: [Talk-GB] OSM augmented reality project - affordable hosting recommendations or Overpass?

2019-02-05 Thread Remek Zajac
I am hosting my OSM based app (https://zikes.website/) on a two-tier
backend:

   - the web frontend and basic user state management on the Google Cloud
   Engine free tier (this is why, when you load the app, it sometimes needs to
   be woken up as it snoozes when nobody's talking to it - which is one of the
   constraints of the free tier)
   - a 32GB dedicated Ubuntu box that i rent from Hetzner
    at 40EUR/pcm. I load most of
   Europe (and California) into RAM for efficient routing. I think this is
   something that you're really after. You can get  16GB/2TB box for 24EUR/pcm
   as i am looking at it now. This is plainly pay-as-you go. The management is
   very easy, but it's a bare-bones linux.

Hope this helps
Remek

On Tue, 5 Feb 2019 at 09:30, Nick Whitelegg 
wrote:

>
> Hi,
>
>
> This weekend at FOSDEM I gave a talk on "Hikar", my augmented reality
> project for walkers/hikers making use of OSM data to show trails and
> virtual signposts on the device. (see
> http://www.free-map.org.uk/common/hikar.html for info and screenshots).
>
>
> At the moment however it only works in Britain, Ireland and Greece due to
> the constraints of my server. Would be great to get it working in the whole
> of Europe (I realise the world might be a bit much at this stage!), so I
> wondered if anyone had any affordable hosting recommendations? Hikar
> downloads GeoJSON from a server containing OSM data (see below) and caches
> it on the device.
>
>
> Basically what I need is an OSM PostGIS database (of the type used for
> Mapnik rendering) but it only needs to contain highways and selected POIs
> (as nodes) - nothing else. Ideally I also need PHP with the postgres
> extension as that is what my service is written in at the moment. However,
> if the best solution was an environment without PHP, I would be prepared to
> rewrite in say node.js.
>
> Would be looking for hosting of not much more than approximately £20/EUR
> 20 per month, perhaps £30/EUR 30 as a maximum.
>
>
> My current server has 1GB of memory and can just about cope with the areas
> above, so I suspect for the whole of Europe more memory would be required.
> Storage requirements for Britain, Ireland and Greece is perhaps (as an
> estimate) 10GB or a little less.
>
>
> The same service would also serve OpenTrailView, a recently resurrected
> project to create a fully FOSS StreetView-type system for walkers and
> hikers. (see opentrailview.org - _very_ early demo!)
>
>
> As an alternative, I was wondering how acceptable it would be to use the
> Overpass API to obtain the data? Downloaded data would be cached on the
> device so for a given area, data would only need to be downloaded once.
>
>
> Thanks,
>
> Nick
>
>
>
> ___
> Talk-GB mailing list
> Talk-GB@openstreetmap.org
> https://lists.openstreetmap.org/listinfo/talk-gb
>
___
Talk-GB mailing list
Talk-GB@openstreetmap.org
https://lists.openstreetmap.org/listinfo/talk-gb


Re: [Talk-GB] OSM augmented reality project - affordable hosting recommendations or Overpass?

2019-02-05 Thread Phil Endecott via Talk-GB

Nick Whitelegg wrote:
I wondered if anyone had any affordable hosting recommendations? 


Would be looking for hosting of not much more than approximately 
£20/EUR 20 per month, perhaps £30/EUR 30 as a maximum.


My current server has 1GB of memory and can just about cope with 
the areas above, so I suspect for the whole of Europe more memory 
would be required. Storage requirements for Britain, Ireland and 
Greece is perhaps (as an estimate) 10GB or a little less.


Amazon Lightsail (in London):

$20/month, 4 GB RAM, 2 CPU cores, 80 GB SSD storage, 4 TB/month bandwidth.

You can add extra storage for $0.10/GB/month.  There are also modest
additional charges for snapshots (for backups).

I have found Lightsail to be very reliable and good value.

The only thing to watch out for is the bandwidth pricing if you exceed
the monthly allowance.  If that's going to be a concern, consider
DigitalOcean.


Regards, Phil.





___
Talk-GB mailing list
Talk-GB@openstreetmap.org
https://lists.openstreetmap.org/listinfo/talk-gb


[Talk-GB] OSM augmented reality project - affordable hosting recommendations or Overpass?

2019-02-05 Thread Nick Whitelegg

Hi,


This weekend at FOSDEM I gave a talk on "Hikar", my augmented reality project 
for walkers/hikers making use of OSM data to show trails and virtual signposts 
on the device. (see http://www.free-map.org.uk/common/hikar.html for info and 
screenshots).

At the moment however it only works in Britain, Ireland and Greece due to the 
constraints of my server. Would be great to get it working in the whole of 
Europe (I realise the world might be a bit much at this stage!), so I wondered 
if anyone had any affordable hosting recommendations? Hikar downloads GeoJSON 
from a server containing OSM data (see below) and caches it on the device.


Basically what I need is an OSM PostGIS database (of the type used for Mapnik 
rendering) but it only needs to contain highways and selected POIs (as nodes) - 
nothing else. Ideally I also need PHP with the postgres extension as that is 
what my service is written in at the moment. However, if the best solution was 
an environment without PHP, I would be prepared to rewrite in say node.js.

Would be looking for hosting of not much more than approximately £20/EUR 20 per 
month, perhaps £30/EUR 30 as a maximum.


My current server has 1GB of memory and can just about cope with the areas 
above, so I suspect for the whole of Europe more memory would be required. 
Storage requirements for Britain, Ireland and Greece is perhaps (as an 
estimate) 10GB or a little less.


The same service would also serve OpenTrailView, a recently resurrected project 
to create a fully FOSS StreetView-type system for walkers and hikers. (see 
opentrailview.org - _very_ early demo!)


As an alternative, I was wondering how acceptable it would be to use the 
Overpass API to obtain the data? Downloaded data would be cached on the device 
so for a given area, data would only need to be downloaded once.


Thanks,

Nick


___
Talk-GB mailing list
Talk-GB@openstreetmap.org
https://lists.openstreetmap.org/listinfo/talk-gb