Closed cyberang3l closed 10 months ago
Supporting HTTP alongside HTTPS helps me use a config like this and serve tiles from a custom local proxy:
{
"name": "OpenFlightMaps",
"servers": [
"localhost:8080"
],
"copyright": "Test local proxy",
"url": "openflightmaps/{z}/{x}/{y}",
"min_zoom_level": 7,
"max_zoom_level": 12,
"tile_width_px": 512,
"tile_height_px": 512,
"protocol": "http",
"enabled": true
},
{
"name": "Norway aeronautical maps",
"servers": [
"localhost:8080"
],
"copyright": "Test local proxy",
"url": "norway_vfr/{z}/{x}/{y}",
"min_zoom_level": 2,
"max_zoom_level": 12,
"tile_width_px": 256,
"tile_height_px": 256,
"protocol": "http",
"enabled": true
}
Tried this out with the https://github.com/cyberang3l/slippy-tile-proxy-server script running locally on my machine, and I could serve the Norway Aeronautical chart ICAO 500.000 as well as the OpenFlightMaps with the latest base and aero layers merged on the fly.
Add a new
protocol
configuration option in the map definitions in mapconfig.json. This defines the communication protocol that is spoken by the tile servers. Theprotocol
config option is optional, and if skipped,https
is assumed by default. The only accepted values arehttps
andhttp
.Most of the public servers nowadays speak HTTPS, but still some use HTTP (without the S). Moreover, when using a local test tile server, setting up a valid SSL certificate can be a pain, so adding support for HTTP servers compliments the "custom online slippy tiles" feature nicely.