Skip to content

chore: remove MongoDB service from Docker Compose and update environm…#72

Merged
harshlocham merged 1 commit into
mainfrom
fix/socket-auth-env-docker-compose
May 20, 2026
Merged

chore: remove MongoDB service from Docker Compose and update environm…#72
harshlocham merged 1 commit into
mainfrom
fix/socket-auth-env-docker-compose

Conversation

@harshlocham
Copy link
Copy Markdown
Owner

This pull request updates the docker-compose.yml configuration to remove MongoDB and its dependencies, and to improve environment variable management for the socket service. The main changes focus on simplifying the service stack and ensuring environment variables are correctly set.

Removal of MongoDB:

  • Removed the mongo service definition, its associated volume (mongo_data), and all references to MongoDB environment variables and dependencies from other services. [1] [2] [3]

Environment Variable and Dependency Updates:

  • Added the .env file and set NODE_ENV to production for the socket service, and included a new WEB_SERVER_URL environment variable.
  • Changed the depends_on syntax for the socket service to a simpler list format.…ent variables

Copilot AI review requested due to automatic review settings May 20, 2026 10:35
@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented May 20, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
chat-app Ready Ready Preview, Comment May 20, 2026 10:36am

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR simplifies the Docker Compose stack by removing the built-in MongoDB service and adjusting how the socket container receives configuration via environment variables.

Changes:

  • Removed the mongo service and the mongo_data volume from docker-compose.yml.
  • Removed hard-coded MONGODB_URI wiring and MongoDB dependencies from other services.
  • Updated the socket service to load .env, set NODE_ENV=production, add WEB_SERVER_URL, and simplified depends_on.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docker-compose.yml
depends_on:
redis:
condition: service_healthy
- redis
Comment thread docker-compose.yml
Comment on lines 24 to 31
env_file:
- .env
environment:
REDIS_URL: redis://redis:6379
MONGODB_URI: mongodb://mongo:27017/chatapp
ORIGIN: http://localhost
SOCKET_SERVER_URL: http://socket:3001
depends_on:
- mongo
- socket
Comment thread docker-compose.yml
Comment on lines 84 to 91
env_file:
- .env
environment:
REDIS_URL: redis://redis:6379
MONGODB_URI: mongodb://mongo:27017/chatapp
SOCKET_SERVER_URL: http://socket:3001
depends_on:
- redis
- mongo
- socket
@harshlocham harshlocham merged commit f5c8f7f into main May 20, 2026
10 checks passed
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.

2 participants