No edit summary |
|||
Line 26: | Line 26: | ||
== Docker Compose == | == Docker Compose == | ||
Docker Compose groups and launches multiple containers together | Docker Compose groups and launches multiple containers together <br> | ||
<code> | <code> | ||
docker-compose -d up | docker-compose -d up |
Revision as of 23:24, 24 April 2020
Docker Compose
Dockerfile provides a declaritive way of building images
Write a Dockerfile
version: '2' services: db: image: mongo:latest container_name: db networks: - appnet web: build: ../. networks: - appnet ports: - "3000" networks: appnet: driver: bridge
Docker Compose
Docker Compose groups and launches multiple containers together
docker-compose -d up
Check logs
docker-logs db
docker-logs web
All
docker compose logs web