Scripts: add script to automatically update the database

This commit is contained in:
Pieter Vander Vennet 2025-03-29 01:46:40 +01:00
parent 72df69a2d6
commit 602cc1f8c9
3 changed files with 44 additions and 47 deletions

View file

@ -13,16 +13,9 @@ Increase the max number of connections. osm2pgsql needs connection one per table
- Validate with `cat /var/lib/postgresql/data/postgresql.conf | grep "max_connections"`
- `sudo docker restart <ID>`
# Seeding the data
> The following steps are also automated in `update.sh`
## Create a database in the SQL-server
Run `vite-node scripts/osm2pgsql/createNewDatabase.ts -- YYYY-MM-DD` to create a new, appropriate, database
## Create export scripts for every layer
Use `npm run build:dbscript`
> The following steps are also automated in .forgejo/workflows/update_database.yml
## Importing data