Verified Commit ce8de45f authored by Peter Stanko's avatar Peter Stanko
Browse files

Docker compose with mount volumes

parent 03327756
Loading
Loading
Loading
Loading
+24 −0
Original line number Diff line number Diff line
version: '3.2'
services:

  portal:
    image: 'kontr2/portal'
    ports:
      - "8000:8000"

  db:
    image: postgres:latest
    restart: always
    container_name: postgres
    environment:
      POSTGRES_PASSWORD: TestPass.42

    volumes:
      - type: volume
        source: db_data
        target: /var/lib/postgresql/data

volumes:
  db_data:

+24 −0
Original line number Diff line number Diff line
version: '3.2'
services:

  portal:
    image: 'kontr2/portal'
    ports:
      - "8000:8000"

  db:
    image: postgres:latest
    restart: always
    container_name: postgres
    environment:
      POSTGRES_PASSWORD: TestPass.42

    volumes:
      - type: volume
        source: db_data
        target: /var/lib/postgresql/data

volumes:
  db_data: