feat: guna MySQL external — host.docker.internal (dev) & 172.17.200.16 (prod)
- Buang service db dan volume dbdata dari compose files - dev: extra_hosts host.docker.internal:host-gateway → capai MySQL Windows host - prod: IP terus 172.17.200.16, tiada extra_hosts diperlukan - .env.docker: DB_HOST=host.docker.internal dengan nota untuk production - entrypoint.sh: default DB_HOST → host.docker.internal Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -28,7 +28,9 @@ LOG_LEVEL=debug
|
||||
|
||||
# ── Database ──────────────────────────────────────────────────────────────────
|
||||
DB_CONNECTION=mysql
|
||||
DB_HOST=db # nama service dalam docker-compose.yml
|
||||
# DEV (Windows): DB_HOST=host.docker.internal ← MySQL pada host Windows
|
||||
# PRODUCTION: DB_HOST=172.17.200.16 ← MySQL server external
|
||||
DB_HOST=host.docker.internal
|
||||
DB_PORT=3306
|
||||
DB_DATABASE=ecert_mbip
|
||||
DB_USERNAME=ecert
|
||||
|
||||
Reference in New Issue
Block a user