add db for unit tests

This commit is contained in:
2026-10-30 10:12:57 +01:00
parent d1981673a2
commit 1c21ad1ef7
2 changed files with 26 additions and 0 deletions
+16
View File
@@ -41,5 +41,21 @@ services:
timeout: 5s
retries: 20
db-test:
image: mysql:5.7
profiles: [testing]
environment:
MYSQL_DATABASE: pollux_test
MYSQL_USER: pollux_test
MYSQL_PASSWORD: testing
MYSQL_ROOT_PASSWORD: testing-root
tmpfs:
- /var/lib/mysql
healthcheck:
test: ["CMD-SHELL", "mysqladmin ping -h 127.0.0.1 -uroot -ptesting-root --silent"]
interval: 2s
timeout: 5s
retries: 30
volumes:
mysql-data: