-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
config info #1
Comments
Whatever the Apache config file is for the virtual host (site) you're deploying. For example, You would typically put the directives within the |
Thank you for getting back to me. I am not getting any data to come through nor am I getting any errors. Would it be possible to get am example .conf to make sure I am doing this correctly? |
Mine looks like this (with paths/domains obfuscated): <VirtualHost *:80>
DocumentRoot "/srv/tile.my.server"
ServerName tile.my.server
<Directory "/srv/tile.my.server">
allow from all
Options None
Require all granted
Header set Access-Control-Allow-Origin "*"
MbtilesEnabled true
MbtilesAdd dem /data/relief/dem.mbtiles
MbtilesAdd contours /data/relief/contours.mbtiles
MbtilesAdd vt /data/vector_tiles/vt.mbtiles
</Directory>
</VirtualHost> Most of this is just standard Apache. Only the four Don't forget you need to restart Apache once you've changed a config file. |
Can you provide reference how you use vt/ in your web page to display map? |
Using the Maplibre GL JS library. |
Yes, I use same - but have hard time understanding how you define layers from mod_mbtiles ? Example would be great! |
Not quite sure what you mean? You don't define any layers in mod_mbtiles - it simply serves out the .mbtiles file (containing vector tiles) that you point it at. Layers are defined when you create the vector tiles with other software, such as tilemaker. |
This is how I've defined my tileserver-gl provided mbtiles for my style.json: "sources": { But somehow I am not able to get mod_mbtiles URL here to provide anything useful? |
mod_mbtiles just serves vector tiles from an mbtiles. Nothing else. It doesn't generate or serve tilejson documents or anything like that. You either need to specify the location of your Apache virtual server (running mod_mbtiles) in the .json file you're pointing to above, or just put it in directly: "sources":{
"openmaptiles":{
"type":"vector",
"tiles":["https://my.tile.server/directory/{z}/{x}/{y}.pbf"],
"minzoom":0,
"maxzoom":14,
"attribution":"Base map © OpenStreetMap"
}
} |
What configuration file do I update and where in the file do I update?
The text was updated successfully, but these errors were encountered: