Skip to content

fix: add explicit compose network aliases for mysql and redis#1375

Open
Zhey-on wants to merge 1 commit intoEnAccess:mainfrom
Zhey-on:fix/docker-compose-network-aliases
Open

fix: add explicit compose network aliases for mysql and redis#1375
Zhey-on wants to merge 1 commit intoEnAccess:mainfrom
Zhey-on:fix/docker-compose-network-aliases

Conversation

@Zhey-on
Copy link

@Zhey-on Zhey-on commented Mar 13, 2026

Brief summary of the change made

This PR adds explicit Docker Compose default-network aliases for database/cache services to avoid DNS resolution failures in local and compose-based setups.

  • mysql now has aliases: db, mysql
  • redis now has alias: redis

Updated files:

  • docker-compose.yml
  • docker-compose-prod.yml
  • docker-compose-dockerhub.yml

closes: #1374

Are there any other side effects of this change that we should be aware of?

No functional side effects expected. This only makes service discovery explicit and more reliable.

Describe how you tested your changes?

Manual validation:

  1. Recreated the stack:
    • docker compose up -d --force-recreate
  2. Verified service hostname resolution from backend container:
    • db, mysql, and redis now resolve to container IPs.
  3. Verified backend auth endpoint with seeded demo credentials:
    • POST /api/auth/login with demo_company_admin@example.com / 123123
    • received valid JWT token.
  4. Verified frontend responds on http://localhost:8001.

Pull Request checklist

  • Meaningful Pull Request title and description
  • Changes tested as described above
  • Added appropriate documentation for the change.
  • Created GitHub issues for any relevant followup/future enhancements if appropriate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Local development login fails because backend cannot resolve db in Docker Compose

1 participant