📜  docker compose vol - 任何代码示例

📅  最后修改于: 2022-03-11 15:00:35.904000             🧑  作者: Mango

代码示例1
# Mount host paths or named volumes, specified as sub-options to a service
  db:
    image: postgres:latest
    volumes:
      - "/var/run/postgres/postgres.sock:/var/run/postgres/postgres.sock"
      - "dbdata:/var/lib/postgresql/data"

volumes:
  dbdata: