Add docker-compose.yml
This commit is contained in:
@@ -0,0 +1,130 @@
|
||||
services:
|
||||
dawarich_db:
|
||||
image: postgis/postgis:17-3.5-alpine
|
||||
container_name: Dawarich-DB
|
||||
hostname: dawarich_db
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U postgres -d dawarich_development"]
|
||||
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: 1026:100
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "redis-cli ping || exit 1"]
|
||||
volumes:
|
||||
- /volume1/docker/dawarich/redis:/data:rw
|
||||
environment:
|
||||
TZ: Europe/Budapest
|
||||
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: FSfdOBMGmwIBdEepezgkqWkTWrOdavhbidGctxILHTuBeRzOPsjaaPxqlOMUroYo
|
||||
APPLICATION_HOSTS: maps.vitarius.hu
|
||||
MIN_MINUTES_SPENT_IN_CITY: 60
|
||||
TIME_ZONE: Europe/Budapest
|
||||
APPLICATION_PROTOCOL: http
|
||||
DISTANCE_UNIT: km
|
||||
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: FSfdOBMGmwIBdEepezgkqWkTWrOdavhbidGctxILHTuBeRzOPsjaaPxqlOMUroYo
|
||||
APPLICATION_HOSTS: maps.vitarius.hu
|
||||
BACKGROUND_PROCESSING_CONCURRENCY: 10
|
||||
APPLICATION_PROTOCOL: https
|
||||
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
|
||||
Reference in New Issue
Block a user