Skip to content

Commit a1b120d

Browse files
author
Rub21
committed
Update docs and merge env var files in db-utils
1 parent e9ee924 commit a1b120d

File tree

14 files changed

+70
-81
lines changed

14 files changed

+70
-81
lines changed

docker-compose.yml

Lines changed: 14 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -46,13 +46,12 @@ services:
4646
- ./data/planet-dump-data:/mnt/data
4747
command: >
4848
/bin/bash -c "
49-
echo 'Set cronjob for planet-dump, every 3 minutes';
50-
sleep 1m;
51-
while :; do echo 'Creating the planet dump file...'; /start.sh; sleep 3m; done;
49+
echo 'Set cronjob for planet-dump, every 4 minutes';
50+
while :; do sleep 4m; echo 'Creating the planet dump file...'; /start.sh; done;
5251
"
5352
env_file:
5453
- ./envs/.env.db
55-
- ./envs/.env.planet-dump
54+
- ./envs/.env.db-utils
5655
- ./envs/.env.cloudprovider
5756
depends_on:
5857
- db
@@ -68,13 +67,12 @@ services:
6867
- ./data/db-backup-restore-data:/mnt/data
6968
command: >
7069
/bin/bash -c "
71-
echo 'Set cron job for backing up DB, every 3m minutes';
72-
sleep 1m;
73-
while :; do echo 'Creating DB backup...'; /start.sh; sleep 3m; done;
70+
echo 'Set cron job for backing up DB, every 4 minutes';
71+
while :; do sleep 4m; echo 'Creating DB backup...'; /start.sh; done;
7472
"
7573
env_file:
7674
- ./envs/.env.db
77-
- ./envs/.env.backup-restore
75+
- ./envs/.env.db-utils
7876
- ./envs/.env.cloudprovider
7977
depends_on:
8078
- db
@@ -97,7 +95,7 @@ services:
9795
"
9896
env_file:
9997
- ./envs/.env.db
100-
- ./envs/.env.replication-job
98+
- ./envs/.env.db-utils
10199
- ./envs/.env.cloudprovider
102100
depends_on:
103101
- db
@@ -113,19 +111,18 @@ services:
113111
- ./data/full-history-data:/mnt/data
114112
command: >
115113
/bin/bash -c "
116-
echo 'Set cron job for full history PBF file, every 3m minutes';
117-
sleep 1m;
118-
while :; do echo 'Creating full history PBF file...'; /start.sh; sleep 3m; done;
114+
echo 'Set cron job for full history PBF file, every 4 minutes';
115+
while :; do sleep 4m; echo 'Creating full history PBF file...'; /start.sh; done;
119116
"
120117
env_file:
121118
- ./envs/.env.db
122-
- ./envs/.env.full-history
119+
- ./envs/.env.db-utils
123120
- ./envs/.env.cloudprovider
124121
depends_on:
125122
- db
126-
######################################################
127-
### Populate apidb from PBF file
128-
######################################################
123+
#####################################################
124+
## Populate apidb from PBF file
125+
#####################################################
129126
populate-apidb:
130127
image: osmseed-populate-apidb:v1
131128
build:
@@ -142,7 +139,7 @@ services:
142139
"
143140
env_file:
144141
- ./envs/.env.db
145-
- ./envs/.env.populate-apidb
142+
- ./envs/.env.db-utils
146143
# ######################################################
147144
# ### Tiler DB
148145
# ######################################################

envs/.env.backup-restore.example

Lines changed: 0 additions & 12 deletions
This file was deleted.

envs/.env.db-utils.example

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
2+
#Osmosis tuning for server, This variable intends to use much as possible the memory in the server
3+
MEMORY_JAVACMD_OPTIONS=2Gi
4+
5+
#######################################
6+
# Environment variables for overwrite full history planet PBF settings
7+
#######################################
8+
# OVERWRITE_FHISTORY_FILE=(true, false)
9+
OVERWRITE_FHISTORY_FILE=false
10+
11+
#######################################
12+
# Environment variables for overwrite planet settings
13+
#######################################
14+
# OVERWRITE_PLANET_FILE=(true, false)
15+
OVERWRITE_PLANET_FILE=false
16+
17+
#######################################
18+
# Environment variables for Replication job settings
19+
#######################################
20+
21+
# TODO:update start.sh and helm templates, for making this customizable
22+
REPLICATION_FOLDER=/replication/minute
23+
24+
#######################################
25+
# Environment variables for minute Replication job settings
26+
#######################################
27+
28+
# Link to a public pbf file
29+
# URL_FILE_TO_IMPORT=https://ds-data-projects.s3.amazonaws.com/dc-output.pbf
30+
# URL_FILE_TO_IMPORT=https://ds-data-projects.s3.amazonaws.com/osm-seed-data/ayac.pbf
31+
URL_FILE_TO_IMPORT=https://download.geofabrik.de/europe/monaco-latest.osm.pbf
32+
33+
#######################################
34+
# Environment variable for DB back up or restore
35+
#######################################
36+
37+
# DB_ACTION=("backup" or "backup")
38+
DB_ACTION=backup
39+
40+
# In case we choose restore, we need to set RESTORE_URL_FILE with a public url file
41+
RESTORE_URL_FILE=http://osmseed.org/osmseed-211104_0055.sql.gz
42+
43+
# TODO: remove this env file from helm template
44+
CLEAN_BACKUPS=false

envs/.env.full-history.example

Lines changed: 0 additions & 8 deletions
This file was deleted.

envs/.env.planet-dump.example

Lines changed: 0 additions & 8 deletions
This file was deleted.

envs/.env.populate-apidb.example

Lines changed: 0 additions & 12 deletions
This file was deleted.

envs/.env.replication-job.example

Lines changed: 0 additions & 9 deletions
This file was deleted.

envs/.env.tiler-imposm.example

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ TILER_IMPORT_FROM=osm
77
TILER_IMPORT_PBF_URL=https://download.geofabrik.de/europe/monaco-latest.osm.pbf
88
SEQUENCE_NUMBER=4768
99
REPLICATION_URL=https://download.openstreetmap.fr/replication/europe/monaco/minute/
10+
OVERWRITE_STATE=false

envs/envs.sh

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,7 @@
22
cp ./envs/.env.web.example ./envs/.env.web
33
cp ./envs/.env.db.example ./envs/.env.db
44
cp ./envs/.env.cloudprovider.example ./envs/.env.cloudprovider
5-
cp ./envs/.env.planet-dump.example ./envs/.env.planet-dump
6-
cp ./envs/.env.backup-restore.example ./envs/.env.backup-restore
7-
cp ./envs/.env.replication-job.example ./envs/.env.replication-job
8-
cp ./envs/.env.full-history.example ./envs/.env.full-history
9-
cp ./envs/.env.populate-apidb.example ./envs/.env.populate-apidb
5+
cp ./envs/.env.db-utils.example ./envs/.env.db-utils
106
cp ./envs/.env.tiler-db.example ./envs/.env.tiler-db
117
cp ./envs/.env.tiler-imposm.example ./envs/.env.tiler-imposm
128
cp ./envs/.env.tiler-server.example ./envs/.env.tiler-server

images/backup-restore/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ This container will create a backup of the osm-seed-db and compress according to
88
In order to run this container we need environment variables, these can be found in the following files👇:
99

1010
- [.env.db.example](./../../envs/.env.db.example)
11-
- [.env.backup-restore.example](./../../envs/.env.backup-restore.example)
11+
- [.env.db-utils.example](./../../envs/.env.db-utils.example)
1212
- [.env.cloudprovider.example](./../../envs/.env.cloudprovider.example)
1313

14-
**Note**: Rename the above files as `.env.db`, `.env.backup-restore` and `.env.cloudprovider`
14+
**Note**: Rename the above files as `.env.db`, `.env.db-utils` and `.env.cloudprovider`
1515

1616
### Running the container
1717

0 commit comments

Comments
 (0)