x-shared: seek_base: &seek_base # build: . image: fairdom/seek:1.18-dev restart: always environment: &seek_base_env RAILS_ENV: production SOLR_PORT: 8983 SOLR_HOST: solr RAILS_LOG_LEVEL: info # debug, info, warn, error or fatal env_file: - docker/db.env volumes: - seek-filestore:/seek/filestore - seek-cache:/seek/tmp/cache depends_on: db: condition: service_healthy solr: condition: service_healthy services: db: # Database implementation, in this case MySQL image: mysql:8.4 container_name: seek-mysql command: - --character-set-server=utf8mb4 - --collation-server=utf8mb4_unicode_ci - --log-error-verbosity=1 # Optional: Enable mysql_native_password if needed for legacy apps # - --mysql-native-password=ON # Optional: restrict foreign keys if needed # - --restrict-fk-on-non-standard-key=OFF restart: always stop_grace_period: 1m30s env_file: - docker/db.env volumes: - seek-mysql-db:/var/lib/mysql healthcheck: test: [ "CMD-SHELL", "mysqladmin ping -h localhost -u $$MYSQL_USER -p$$MYSQL_PASSWORD --silent", ] interval: 10s timeout: 5s retries: 5 start_period: 20s seek: # The SEEK application <<: *seek_base container_name: seek command: docker/entrypoint.sh ports: - "3000:3000" environment: <<: *seek_base_env NO_ENTRYPOINT_WORKERS: 1 healthcheck: test: ["CMD", "curl", "-f", "http://localhost:3000/up"] interval: 30s timeout: 5s retries: 5 start_period: 20s seek_workers: # The SEEK delayed job workers <<: *seek_base container_name: seek-workers environment: <<: *seek_base_env QUIET_SUPERCRONIC: 1 command: docker/start_workers.sh healthcheck: test: ["CMD", "bash", "script/check_worker_pids.sh"] retries: 5 solr: image: solr:8.11.4 container_name: seek-solr restart: always environment: SOLR_JAVA_MEM: -Xms512m -Xmx1024m volumes: - seek-solr-data:/var/solr/ - ./solr/seek/conf:/opt/solr/server/solr/configsets/seek_config/conf healthcheck: test: ["CMD", "curl", "-sf", "http://localhost:8983/solr/seek/admin/ping"] interval: 30s timeout: 5s retries: 6 start_period: 30s entrypoint: - docker-entrypoint.sh - solr-precreate - seek - /opt/solr/server/solr/configsets/seek_config volumes: seek-filestore: external: true seek-mysql-db: external: true seek-solr-data: external: true seek-cache: external: true