Created
January 29, 2021 10:02
-
-
Save ovuruska/b63ab4f184f1249542ba20892ac74483 to your computer and use it in GitHub Desktop.
Docker anchor example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3.5" | |
services: | |
camera_1: &camera | |
restart: unless-stopped | |
container_name: camera_1 | |
build: ./camera | |
environment: | |
PORT: 10000 | |
network_mode: host | |
ports: | |
- "10000:10000" | |
expose: | |
- "10000" | |
camera_2: | |
<<: *camera | |
container_name: camera_2 | |
environment: | |
PORT: 10001 | |
ports: | |
- "10001:10001" | |
expose: | |
- "10001" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment