forked from MapComplete/MapComplete
Scripts: improve documentation and try to speed up things
This commit is contained in:
parent
e512b40117
commit
fe39817d14
3 changed files with 53 additions and 52 deletions
|
@ -1,13 +1,19 @@
|
|||
# Setting up a synced OSM-server for quick layer access
|
||||
|
||||
## Requirements
|
||||
|
||||
Debian machine (e.g. Ubuntu)
|
||||
|
||||
`apt install osmium-tool docker.io osm2pgsql`
|
||||
|
||||
## Setting up the SQL-server (only once):
|
||||
|
||||
`sudo docker run --name some-postgis -e POSTGRES_PASSWORD=password -e POSTGRES_USER=user -d -p 5444:5432 -v ~/data/pgsql/:/var/lib/postgresql/data postgis/postgis`
|
||||
|
||||
Increase the max number of connections. osm2pgsql needs connection one per table (and a few more), and since we are making one table per layer in MapComplete, this amounts to a lot.
|
||||
|
||||
- Open PGAdmin, open the PGSQL-tool (CLI-button at the top); alternativly: psql --host=172.17.0.1 --port=5444
|
||||
--user=user
|
||||
- Open PGAdmin, open the PGSQL-tool (CLI-button at the top); alternativly:
|
||||
`psql --host=172.17.0.1 --port=5444 --user=user`
|
||||
- Run `show config_file;` to get the config file location (in docker). This is probably
|
||||
`/var/lib/postgresql/data/postgresql.conf`
|
||||
- In a terminal, run `sudo docker exec -i <docker-container-id> bash` (run `sudo docker ps` to get the container id)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue