Skip to content

Commit 57bdcef

Browse files
author
Rub21
committed
Merge branch 'develop' into azure/storage
2 parents 8c9603e + 0c8550b commit 57bdcef

25 files changed

+617
-639
lines changed

INSTALL.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,12 @@ You will need `docker` and `docker-compose` installed on your system.
1313

1414
### Run locally
1515

16-
Osm-seed contains different containers, you may need to comment out some of them at docker-compose.yml according to your use case.
16+
OSM Seed contains different containers, these are split into multiple docker compose files in `compose/`. The `web.yml` is the default with a API database and openstreetmap-website container. Make sure the required environment files are created. Example envs are in `envs/`. To create an env copy `envs/.env.db.example` to `.env.db` and edit as appropriate.
1717

18-
Copy the required environment files form `envs/` folder, e.g `envs/.env.db.example` to `.env.db` and edit as appropriate.
1918

20-
Run `docker-compose build` to build all Dockerfiles defined in `docker-compose.yml`.
21-
22-
Run `docker-compose up` to run all containers defined in `docker-compose.yml`
19+
You can use any container required by extending the `docker compose up` command like this:
20+
* To run just the website `docker compose -f compose/web.yml up`
21+
* To run website and import some data to the DB `docker compose -f compose/web.yml -f compose/populate-apidb.yml up`
2322

2423
Once `docker-compose` is running, you should be able to access a local instance of services:
2524

@@ -32,7 +31,6 @@ Once `docker-compose` is running, you should be able to access a local instance
3231
- Overpass API on `http://localhost:8081`
3332
- Tasking Manager API on `http://localhost:5050`
3433
- Taginfo API website on `http://localhost:4567`
35-
- OpenStreetMap website on `http://localhost:80`
3634

3735
NOTE:
3836

compose/db-backup-restore.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
version: '3'
2+
services:
3+
#####################################################
4+
## OSM Database backup and restore section
5+
#####################################################
6+
db-backup-restore:
7+
image: osmseed-backup-restore:v1
8+
build:
9+
context: ../images/backup-restore
10+
dockerfile: Dockerfile
11+
volumes:
12+
- ../data/db-backup-restore-data:/mnt/data
13+
command: >
14+
/bin/bash -c "
15+
echo 'Set cron job for backing up DB, every 4 minutes';
16+
while :; do sleep 4m; echo 'Creating DB backup...'; /start.sh; done;
17+
"
18+
env_file:
19+
- ../envs/.env.db
20+
- ../envs/.env.db-utils
21+
- ../envs/.env.cloudprovider
22+
depends_on:
23+
- db

compose/full-history.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
version: '3'
2+
services:
3+
#####################################################
4+
## OSM full planet replication
5+
#####################################################
6+
full-history:
7+
image: osmseed-full-history:v1
8+
build:
9+
context: ../images/full-history
10+
dockerfile: Dockerfile
11+
volumes:
12+
- ../data/full-history-data:/mnt/data
13+
command: >
14+
/bin/bash -c "
15+
echo 'Set cron job for full history PBF file, every 4 minutes';
16+
while :; do sleep 4m; echo 'Creating full history PBF file...'; /start.sh; done;
17+
"
18+
env_file:
19+
- ../envs/.env.db
20+
- ../envs/.env.db-utils
21+
- ../envs/.env.cloudprovider
22+
depends_on:
23+
- db

compose/nominatim.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
version: '3'
2+
services:
3+
#####################################################
4+
## Nominatim DB-API section
5+
#####################################################
6+
nominatim-db:
7+
image: nominatim-db:v1
8+
build:
9+
context: ../images/nominatim
10+
dockerfile: Dockerfile
11+
ports:
12+
- '5434:5432'
13+
volumes:
14+
- ../data/nominatim-db-data:/var/lib/postgresql/data
15+
command: >
16+
/bin/bash -c "
17+
sh /app/start.sh
18+
"
19+
env_file:
20+
- ../envs/.env.nominatim
21+
nominatim-api:
22+
image: nominatim-api:v1
23+
build:
24+
context: ../images/nominatim
25+
dockerfile: Dockerfile
26+
ports:
27+
- '7070:8080'
28+
entrypoint: sh /app/startapache.sh
29+
env_file:
30+
- ../envs/.env.nominatim

compose/overpass.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
version: '3'
2+
services:
3+
######################################################
4+
### Overpass API section
5+
######################################################
6+
overpass-api:
7+
image: osmseed-overpass-api:v1
8+
build:
9+
context: ../images/overpass-api
10+
dockerfile: Dockerfile
11+
ports:
12+
- '8081:80'
13+
volumes:
14+
- ../data/overpass-api-db-data:/db
15+
env_file:
16+
- ../envs/.env.overpass

compose/planet-dump.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
version: '3'
2+
services:
3+
######################################################
4+
### OSM processor and also use this image as base for other containers
5+
######################################################
6+
osm-processor:
7+
image: osmseed-osm-processor:v1
8+
build:
9+
context: ../images/osm-processor
10+
dockerfile: Dockerfile
11+
######################################################
12+
### Planet replication section
13+
######################################################
14+
planet-dump:
15+
image: osmseed-planet-dump:v1
16+
build:
17+
context: ./images/planet-dump
18+
dockerfile: Dockerfile
19+
volumes:
20+
- ./data/planet-dump-data:/mnt/data
21+
command: >
22+
/bin/bash -c "
23+
echo 'Set cronjob for planet-dump, every 4 minutes';
24+
while :; do sleep 4m; echo 'Creating the planet dump file...'; /start.sh; done;
25+
"
26+
env_file:
27+
- ../envs/.env.db
28+
- ../envs/.env.db-utils
29+
- ../envs/.env.cloudprovider
30+
depends_on:
31+
- db

compose/populate-apidb.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
version: '3'
2+
services:
3+
#####################################################
4+
## Populate apidb from PBF file
5+
#####################################################
6+
populate-apidb:
7+
image: osmseed-populate-apidb:v1
8+
build:
9+
context: ../images/populate-apidb
10+
dockerfile: Dockerfile
11+
volumes:
12+
- ../data/populate-apidb-data:/mnt/data
13+
command: >
14+
/bin/bash -c "
15+
echo Sleep for a while populate-apidb!;
16+
sleep 4m;
17+
echo Starting populate-apidb!;
18+
/start.sh
19+
"
20+
env_file:
21+
- ../envs/.env.db
22+
- ../envs/.env.db-utils

compose/replication.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
version: '3'
2+
services:
3+
######################################################
4+
### OSM minute replication files section
5+
######################################################
6+
replication-job:
7+
image: osmseed-replication-job:v1
8+
build:
9+
context: ../images/replication-job
10+
dockerfile: Dockerfile
11+
volumes:
12+
- ../data/replication-job-data:/mnt/data
13+
command: >
14+
/bin/bash -c "
15+
echo Sleep the replication-job for 1 minute;
16+
sleep 1m;
17+
echo Creating the replication files!;
18+
/start.sh
19+
"
20+
env_file:
21+
- ../envs/.env.db
22+
- ../envs/.env.db-utils
23+
- ../envs/.env.cloudprovider
24+
depends_on:
25+
- db

compose/taginfo.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
version: '3'
2+
services:
3+
# #####################################################
4+
# ## Taginfo section
5+
# #####################################################
6+
taginfo:
7+
image: osmseed-taginfo:v1
8+
build:
9+
context: ../images/taginfo
10+
dockerfile: Dockerfile
11+
ports:
12+
- '4567:80'
13+
volumes:
14+
- ../data/taginfo-data:/apps/data/
15+
command: >
16+
/bin/bash -c "
17+
./start.sh"
18+
env_file:
19+
- ../envs/.env.taginfo

compose/tasking-manager.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
version: '3'
2+
services:
3+
######################################################
4+
### Tasking Manager section
5+
######################################################
6+
tasking-manager-api:
7+
image: osmseed-tasking-manager-api:v1
8+
build:
9+
context: ../images/tasking-manager-api
10+
dockerfile: Dockerfile
11+
ports:
12+
- '5000:5000'
13+
volumes:
14+
- ../data/tasking-manager-api-db:/db
15+
env_file:
16+
- ../envs/.env.tasking-manager

0 commit comments

Comments
 (0)