Update compose.yaml
This commit is contained in:
100
compose.yaml
100
compose.yaml
@@ -1,50 +1,50 @@
|
|||||||
|
|
||||||
services:
|
services:
|
||||||
api-server:
|
api-server:
|
||||||
build: # Assuming Dockerfile for API is in the root directory
|
build: # Assuming Dockerfile for API is in the root directory
|
||||||
context: ./ # Root directory context
|
context: ./ # Root directory context
|
||||||
dockerfile: src/api-server/Dockerfile
|
dockerfile: src/api-server/Dockerfile
|
||||||
container_name: DwinzoApi_V0_end
|
container_name: DwinzoApi_V0_end
|
||||||
environment:
|
environment:
|
||||||
NODE_ENV: development
|
NODE_ENV: development
|
||||||
ports:
|
ports:
|
||||||
- "4999:4999" # Host port 5000 mapped to container's port 5000
|
- "4999:4999" # Host port 5000 mapped to container's port 5000
|
||||||
expose:
|
expose:
|
||||||
- 4999
|
- 4999
|
||||||
depends_on:
|
depends_on:
|
||||||
- mongo
|
- mongo
|
||||||
networks:
|
networks:
|
||||||
- DwinzoMajor
|
- DwinzoMajor
|
||||||
|
|
||||||
socket-server:
|
socket-server:
|
||||||
build: # Assuming Dockerfile for Socket server is in the root directory
|
build: # Assuming Dockerfile for Socket server is in the root directory
|
||||||
context: ./ # Root directory context
|
context: ./ # Root directory context
|
||||||
dockerfile: src/socket-server/Dockerfile
|
dockerfile: src/socket-server/Dockerfile
|
||||||
container_name: DwinzoSocket_V0_end
|
container_name: DwinzoSocket_V0_end
|
||||||
environment:
|
environment:
|
||||||
NODE_ENV: development
|
NODE_ENV: development
|
||||||
ports:
|
ports:
|
||||||
- "7999:7999" # Changed host port to avoid conflict with API server
|
- "7999:7999" # Changed host port to avoid conflict with API server
|
||||||
expose:
|
expose:
|
||||||
- 7999
|
- 7999
|
||||||
depends_on:
|
depends_on:
|
||||||
- mongo
|
- mongo
|
||||||
networks:
|
networks:
|
||||||
- DwinzoMajor # Socket server on the same network as the API server
|
- DwinzoMajor # Socket server on the same network as the API server
|
||||||
|
|
||||||
mongo:
|
mongo:
|
||||||
image: mongo:latest
|
image: mongo:latest
|
||||||
container_name: mongo-Dwinzocontainer
|
container_name: mongo-Dwinzocontainer-demo
|
||||||
ports:
|
ports:
|
||||||
- "27021:27017"
|
- "27021:27017"
|
||||||
volumes:
|
volumes:
|
||||||
- mongo-data:/data/db
|
- mongo-data:/data/db
|
||||||
networks:
|
networks:
|
||||||
- DwinzoMajor # Mongo is now on the same network
|
- DwinzoMajor # Mongo is now on the same network
|
||||||
|
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
mongo-data: # Persistent volume for MongoDB data
|
mongo-data: # Persistent volume for MongoDB data
|
||||||
networks:
|
networks:
|
||||||
DwinzoMajor:
|
DwinzoMajor:
|
||||||
driver: bridge
|
driver: bridge
|
||||||
|
|||||||
Reference in New Issue
Block a user