Nadat ik photon opnieuw had geïnstalleerd werken de twee dockers als een zonnetje.
Voor de volledigheid:
Dawarich met reverse geocoding door photon:
Photon---------Docker1---------------------
version: '3.7'
services:
photon:
image: rtuszik/photon-docker:latest
container_name: photon
environment:
- COUNTRY_CODE=nl
- PUID=1036
- PGID=100
- TZ=Europe/Amsterdam
volumes:
- photon_data:/photon/photon_data
restart: unless-stopped
ports:
- 2322:2322
volumes:
photon_data:
driver: local # Define the driver and options under the volume name
driver_opts:
type: none
device: /volume1/docker/photon/photon_data
o: bind[/
------------------Docker2-------------------
Dawarich:
services:
dawarich_db:
image: postgis/postgis:17-3.5-alpine
container_name: Dawarich-DB
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d dawarich"]
interval: 10s
retries: 5
start_period: 30s
timeout: 10s
volumes:
- /volume1/docker/dawarich/db:/var/lib/postgresql/data:rw
- /volume1/docker/dawarich/shared:/var/shared:rw
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: password
POSTGRES_DB: dawarich_development
shm_size: 1G
restart: on-failure:5
dawarich_redis:
image: redis:7.4-alpine
command: redis-server
container_name: Dawarich-REDIS
user: 1036:100
healthcheck:
test: ["CMD-SHELL", "redis-cli ping || exit 1"]
volumes:
- /volume1/docker/dawarich/redis:/data:rw
environment:
TZ: Europe/Amsterdam
restart: on-failure:5
dawarich_app:
image: freikin/dawarich:latest
container_name: Dawarich
volumes:
- /volume1/docker/dawarich/public:/var/app/public:rw
- /volume1/docker/dawarich/watched:/var/app/tmp/imports/watched:rw
- /volume1/docker/dawarich/storage:/var/app/storage:rw
ports:
- 3639:3000
stdin_open: true
tty: true
entrypoint: web-entrypoint.sh
command: ['bin/rails', 'server', '-p', '3000', '-b', '::']
environment:
RAILS_ENV: development
REDIS_URL: redis://dawarich_redis:6379
DATABASE_HOST: dawarich_db
DATABASE_USERNAME: postgres
DATABASE_PASSWORD: password
DATABASE_NAME: dawarich_development
SELF_HOSTED: true
STORE_GEODATA: true
SECRET_KEY_BASE: ##################################################
APPLICATION_HOSTS: dawarich.#######.nl (#=eigen domeinnaam)
MIN_MINUTES_SPENT_IN_CITY: 60
TIME_ZONE: Europe/Amsterdam
APPLICATION_PROTOCOL: http
DISTANCE_UNIT: km
REVERSE_GEOCODING_ENABLED: true
PHOTON_API_HOST: 192.168.1.58:2322
PHOTON_API_USE_HTTPS: false
#GEOAPIFY_API_KEY: ###################( ongebruikt )
PROMETHEUS_EXPORTER_ENABLED: false
PROMETHEUS_EXPORTER_HOST: 0.0.0.0
PROMETHEUS_EXPORTER_PORT: 9394
ENABLE_TELEMETRY: false # More on telemetry: https://dawarich.app/docs/tutorials/telemetry
logging:
driver: "json-file"
options:
max-size: "100m"
max-file: "5"
healthcheck:
test: ["CMD-SHELL", "wget -qO - http://127.0.0.1:3000/api/v1/health | grep -q '\"status\"\\s*:\\s*\"ok\"'"]
interval: 10s
retries: 30
start_period: 30s
timeout: 10s
depends_on:
dawarich_db:
condition: service_healthy
dawarich_redis:
condition: service_healthy
restart: on-failure:5
dawarich_sidekiq:
image: freikin/dawarich:latest
container_name: Dawarich-SIDEKIQ
healthcheck:
test: ["CMD-SHELL", "pgrep -f sidekiq"]
interval: 10s
retries: 30
start_period: 30s
timeout: 10s
volumes:
- /volume1/docker/dawarich/public:/var/app/public:rw
- /volume1/docker/dawarich/watched:/var/app/tmp/imports/watched:rw
- /volume1/docker/dawarich/storage:/var/app/storage:rw
stdin_open: true
tty: true
entrypoint: sidekiq-entrypoint.sh
command: ['sidekiq']
environment:
RAILS_ENV: development
REDIS_URL: redis://dawarich_redis:6379
DATABASE_HOST: dawarich_db
DATABASE_USERNAME: postgres
DATABASE_PASSWORD: password
DATABASE_NAME: dawarich_development
SECRET_KEY_BASE: ##############################################
APPLICATION_HOSTS: dawarich.#######.nl (#=eigen domeinnaam)
BACKGROUND_PROCESSING_CONCURRENCY: 10
APPLICATION_PROTOCOL: http
REVERSE_GEOCODING_ENABLED: true
PHOTON_API_HOST: 192.168.1.58:2322
PHOTON_API_USE_HTTPS: false
#GEOAPIFY_API_KEY: ###################( ongebruikt )
PROMETHEUS_EXPORTER_ENABLED: false
PROMETHEUS_EXPORTER_HOST: dawarich_app
PROMETHEUS_EXPORTER_PORT: 9394
SELF_HOSTED: true
STORE_GEODATA: true
logging:
driver: "json-file"
options:
max-size: "100m"
max-file: "5"
depends_on:
dawarich_db:
condition: service_healthy
dawarich_redis:
condition: service_healthy
dawarich_app:
condition: service_healthy
restart: on-failure:5