add a generate_tile command

This commit is contained in:
nobohan 2023-06-22 16:52:25 +02:00
parent 9da2918abc
commit c2ce0cdd36
2 changed files with 24 additions and 1 deletions

View File

@ -50,8 +50,21 @@ INFO:root: Import complete
docker-compose run --rm map run
```
The tiles are available on http://192.168.176.2/ (should be on http://localhost:8080/ though...)
The tiles are available on http://192.168.176.2/ or something like that. Have a look at the docker container to know which is the IP address: there is a message like "Could not reliably determine the server's fully qualified domain name, using 192.168.176.2.". (should be on http://localhost:8080/ though...)
#### Generate tiles from a list
There's a script in utils to generate a list of tiles to be used to generate the tiles.
```bash
python3 generate-tiles-list.py > tiles.list
```
Move this `tiles.list` file in the `/tiles/` directory and then run:
```bash
docker-compose run --rm map generate_tiles
```
## Original README

10
run.sh
View File

@ -199,5 +199,15 @@ if [ "$1" == "run" ]; then
exit 0
fi
if [ "$1" == "generate_tiles" ]; then
service postgresql start
service apache2 restart
sudo -u renderer renderd -c /etc/renderd.conf
cat /data/tiles/default/tiles.list | render_list --map default
fi
echo "invalid command"
exit 1