# Note that .env file will automatically populate # variables in this file. # If these variables are also set on the host system, # those will be used over the .env file. # See https://vsupalov.com/docker-arg-env-variable-guide/ x-common-environment: &common-server-environment APNS_IS_PRODUCTION: ${APNS_IS_PRODUCTION} APNS_BUNDLE_ID: ${APNS_BUNDLE_ID} APNS_TEAM_ID: ${APNS_TEAM_ID} APNS_KEY_ID: ${APNS_KEY_ID} APNS_PRIVATE_KEY: ${APNS_PRIVATE_KEY} PARKING_LOGGING_INTERVAL_MS: ${PARKING_LOGGING_INTERVAL_MS} REDIS_URL: redis://redis:6379 REDIS_USE_TLS: 0 RATE_LIMITS_DISABLED: ${RATE_LIMITS_DISABLED} RATE_LIMIT_WINDOW_MS: ${RATE_LIMIT_WINDOW_MS} RATE_LIMIT_DELAY_AFTER_REQUESTS: ${RATE_LIMIT_DELAY_AFTER_REQUESTS} RATE_LIMIT_DELAY_MULTIPLIER_MS: ${RATE_LIMIT_DELAY_MULTIPLIER_MS} services: dev: build: . command: npm run start:dev ports: - "4000:4000" depends_on: - redis environment: <<: *common-server-environment volumes: - .:/usr/src/app test: build: . command: npm run test depends_on: - redis-no-persistence environment: REDIS_URL: redis://redis-no-persistence:6379 RATE_LIMITS_DISABLED: 1 volumes: - .:/usr/src/app redis: image: redis/redis-stack:7.2.0-v17 container_name: redis-timeseries ports: - "6379:6379" volumes: - redis_data:/data - ./redis-stack.conf:/redis-stack.conf command: redis-stack-server /redis-stack.conf redis-no-persistence: image: redis/redis-stack:7.2.0-v17 container_name: redis-timeseries-no-persistence ports: - "6379:6379" volumes: redis_data: # Add this volume definition