Skip to content

Instantly share code, notes, and snippets.

@bchapuis
Created October 7, 2020 09:38
Show Gist options
  • Save bchapuis/9f109cf736f85f4944cabf93c02dc91a to your computer and use it in GitHub Desktop.
Save bchapuis/9f109cf736f85f4944cabf93c02dc91a to your computer and use it in GitHub Desktop.
Baremaps OSM Switzerland Configuration
id: 'openstreetmap'
center:
lon: 6.5743
lat: 46.5189
zoom: 14
bounds:
minLon: 5.8358
minLat: 45.6591
maxLon: 10.9794
maxLat: 47.8700
minZoom: 12
maxZoom: 14
layers:
- id: 'aeroway'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'aeroway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'aeroway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'aeroway' AND tags -> 'type' = 'multipolygon'
- id: 'waterway'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'waterway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'waterway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'waterway' AND tags -> 'type' = 'multipolygon'
- id: 'landuse'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'landuse'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'landuse'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'landuse' AND tags -> 'type' = 'multipolygon'
- id: 'railway'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'railway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'railway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'railway' AND tags -> 'type' = 'multipolygon'
- id: 'highway'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'highway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'highway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'highway' AND tags -> 'type' = 'multipolygon'
- id: 'public_transport'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'public_transport'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'public_transport'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'public_transport' AND tags -> 'type' = 'multipolygon'
- id: 'aerialway'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'aerialway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'aerialway'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'aerialway' AND tags -> 'type' = 'multipolygon'
- id: 'geological'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'geological'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'geological'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'geological' AND tags -> 'type' = 'multipolygon'
- id: 'building'
type: 'polygon'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'building'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'building'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'building' AND tags -> 'type' = 'multipolygon'
- id: 'amenity'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'amenity'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'amenity'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'amenity' AND tags -> 'type' = 'multipolygon'
- id: 'craft'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'craft'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'craft'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'craft' AND tags -> 'type' = 'multipolygon'
- id: 'emergency'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'emergency'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'emergency'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'emergency' AND tags -> 'type' = 'multipolygon'
- id: 'historic'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'historic'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'historic'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'historic' AND tags -> 'type' = 'multipolygon'
- id: 'leisure'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'leisure'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'leisure'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'leisure' AND tags -> 'type' = 'multipolygon'
- id: 'man_made'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'man_made'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'man_made'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'man_made' AND tags -> 'type' = 'multipolygon'
- id: 'military'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'military'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'military'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'military' AND tags -> 'type' = 'multipolygon'
- id: 'natural'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'natural'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'natural'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'natural' AND tags -> 'type' = 'multipolygon'
- id: 'office'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'office'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'office'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'office' AND tags -> 'type' = 'multipolygon'
- id: 'place'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'place'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'place'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'place' AND tags -> 'type' = 'multipolygon'
- id: 'power'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'power'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'power'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'power' AND tags -> 'type' = 'multipolygon'
- id: 'route'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'route'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'route'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'route' AND tags -> 'type' = 'multipolygon'
- id: 'shop'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'shop'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'shop'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'shop' AND tags -> 'type' = 'multipolygon'
- id: 'sport'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'sport'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'sport'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'sport' AND tags -> 'type' = 'multipolygon'
- id: 'telecom'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'telecom'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'telecom'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'telecom' AND tags -> 'type' = 'multipolygon'
- id: 'tourism'
type: 'geometry'
queries:
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_nodes WHERE tags ? 'tourism'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_ways WHERE tags ? 'tourism'
- minZoom: 12
maxZoom: 20
sql: SELECT id, tags, geom FROM osm_relations WHERE tags ? 'tourism' AND tags -> 'type' = 'multipolygon'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment