2024-11-12 21:51:56 -03:00
|
|
|
services:
|
|
|
|
testing:
|
|
|
|
profiles:
|
|
|
|
- testing
|
|
|
|
build: .
|
2025-07-22 13:18:00 +00:00
|
|
|
container_name: incoviba_tests
|
2024-11-12 21:51:56 -03:00
|
|
|
env_file:
|
|
|
|
- ${APP_PATH:-.}/.test.env
|
|
|
|
- ./.key.env
|
|
|
|
volumes:
|
|
|
|
- ${APP_PATH:-.}/:/code
|
|
|
|
- ./logs/test:/logs
|
|
|
|
command: [ '/code/bin/phpunit-watcher', 'watch' ]
|
2025-07-22 13:18:00 +00:00
|
|
|
networks:
|
|
|
|
- testing
|
2024-11-12 21:51:56 -03:00
|
|
|
depends_on:
|
2025-07-22 13:18:00 +00:00
|
|
|
test-db:
|
|
|
|
condition: service_healthy
|
|
|
|
test-redis:
|
|
|
|
condition: service_healthy
|
|
|
|
test-mqtt:
|
|
|
|
condition: service_started
|
2024-11-12 21:51:56 -03:00
|
|
|
|
|
|
|
test-db:
|
|
|
|
profiles:
|
|
|
|
- testing
|
2025-07-22 13:18:00 +00:00
|
|
|
image: mariadb:latest
|
2024-11-12 21:51:56 -03:00
|
|
|
container_name: incoviba_test_db
|
|
|
|
env_file: ${APP_PATH:-.}/.test.db.env
|
|
|
|
volumes:
|
2025-07-22 13:18:00 +00:00
|
|
|
- test-db:/var/lib/mysql}
|
|
|
|
healthcheck:
|
|
|
|
test: [ "CMD", "mariadb-admin", "ping", "-h", "localhost" ]
|
|
|
|
interval: 5s
|
|
|
|
timeout: 5s
|
|
|
|
retries: 10
|
2024-11-28 11:41:19 -03:00
|
|
|
networks:
|
2025-07-22 13:18:00 +00:00
|
|
|
- testing
|
|
|
|
|
|
|
|
test-redis:
|
|
|
|
profiles:
|
|
|
|
- testing
|
|
|
|
image: redis:latest
|
|
|
|
container_name: incoviba_test_redis
|
|
|
|
healthcheck:
|
|
|
|
test: [ "CMD", "redis-cli", "--raw", "incr", "ping" ]
|
|
|
|
interval: 5s
|
|
|
|
timeout: 5s
|
|
|
|
retries: 5
|
|
|
|
networks:
|
|
|
|
- testing
|
|
|
|
|
|
|
|
test-mqtt:
|
|
|
|
profiles:
|
|
|
|
- testing
|
|
|
|
image: maateen/docker-beanstalkd
|
|
|
|
container_name: incoviba_test_mqtt
|
|
|
|
healthcheck:
|
|
|
|
test: [ "CMD", "nc", "-z", "localhost", "11300" ]
|
|
|
|
interval: 5s
|
|
|
|
timeout: 5s
|
|
|
|
retries: 5
|
|
|
|
networks:
|
|
|
|
- testing
|
2024-11-12 21:51:56 -03:00
|
|
|
|
|
|
|
volumes:
|
|
|
|
test-db: {}
|
2024-11-28 11:41:19 -03:00
|
|
|
|
|
|
|
networks:
|
2025-07-22 13:18:00 +00:00
|
|
|
testing: {}
|