Allow more flexible development DB config

This commit is contained in:
Emi Matchu 2025-11-11 12:20:25 -08:00
parent 4e2c99d4dd
commit b257de85f2
2 changed files with 12 additions and 9 deletions

View file

@ -20,11 +20,14 @@ services:
depends_on:
- mysql
environment:
DB_USER: root
mysql:
image: mariadb:10.6
restart: unless-stopped
environment:
MYSQL_ALLOW_EMPTY_PASSWORD: 'true'
MARIADB_ALLOW_EMPTY_ROOT_PASSWORD: 'true'
volumes:
- mysql-data:/var/lib/mysql
networks:

View file

@ -3,7 +3,7 @@ development:
adapter: mysql2
host: <%= ENV.fetch("DB_HOST", "localhost") %>
database: openneo_impress
username: root
username: <%= ENV.fetch("DB_USER", ENV.fetch("USER", "root")) %>
pool: 5
encoding: utf8mb4
collation: utf8mb4_unicode_520_ci
@ -14,7 +14,7 @@ development:
adapter: mysql2
host: <%= ENV.fetch("DB_HOST", "localhost") %>
database: openneo_id
username: root
username: <%= ENV.fetch("DB_USER", ENV.fetch("USER", "root")) %>
pool: 2
variables:
sql_mode: TRADITIONAL
@ -25,7 +25,7 @@ test:
adapter: mysql2
host: <%= ENV.fetch("DB_HOST", "localhost") %>
database: openneo_impress_test
username: root
username: <%= ENV.fetch("DB_USER", ENV.fetch("USER", "root")) %>
pool: 5
encoding: utf8mb4
collation: utf8mb4_unicode_520_ci
@ -36,7 +36,7 @@ test:
adapter: mysql2
host: <%= ENV.fetch("DB_HOST", "localhost") %>
database: openneo_id_test
username: root
username: <%= ENV.fetch("DB_USER", ENV.fetch("USER", "root")) %>
pool: 2
variables:
sql_mode: TRADITIONAL