-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
18 lines (16 loc) · 818 Bytes
/
Copy pathdocker-compose.yml
File metadata and controls
18 lines (16 loc) · 818 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# Specify the version of the Docker Compose.
version: "3.9"
# Define the services and applications that make up your application.
services:
demo-app:
build: ./demo-app # Path to the directory containing the Dockerfile for building the demo-app image.
ports:
- 3000:3000 # Maps port 3000 on the host to port 3000 in the container, making the app accessible on the host.
volumes:
- ./demo-app:/app # Mounts the host directory './demo-app' to '/app' in the container.
- /app/node_modules # Anonymous Volume
networks:
- demo-network # Connects the demo-app to the 'demo-network' network.
networks:
demo-network: # Defines a network named 'demo-network'.
driver: bridge # Uses the bridge driver for the network, which is the default and most common network type in Docker.