Link to home
Start Free TrialLog in
Avatar of Simon Leung
Simon Leung

asked on

Docker compose file

Inside the docker compose file, I see there is backend or frontend in "networks" keyword. What does it use for ? Do I need to setup backend and frontend network ?

Thx
Avatar of ssvl
ssvl
Flag of United States of America image

Those are place holder options for your isolated network configs eg:- 

version: "3"
services:

  proxy:
    build: ./proxy
    networks:
      - frontend
  app:
    build: ./app
    networks:
      - frontend
      - backend
  db:
    image: postgres
    networks:
      - backend

networks:
  frontend:
    # Use a custom driver
    driver: custom-driver-1
  backend:
    # Use a custom driver which takes special options
    driver: custom-driver-2
    driver_opts:
      foo: "1"
      bar: "2

Open in new window


Avatar of Simon Leung
Simon Leung

ASKER

backend:    
 # Use a custom driver which takes special options    
driver: custom-driver- 2

What does custom-driver mean ? Is it a driver file in particular folder in Linux ?


ASKER CERTIFIED SOLUTION
Avatar of ssvl
ssvl
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial