version: "3"

volumes:
  plumedb-data:
  plume-data:
  plume-searchidx:

networks:
  docker_default:
    external: true

services:
  plumedb:
    image: postgres:10.5
    container_name: plumedb
    env_file: plume.env
    restart: always
    volumes:
      - "plumedb-data:/var/lib/postgresql/data"
    networks:
     - docker_default

  plume:
    image: registry.picasoft.net/pica-plume
    container_name: plume
    env_file: plume.env
    restart: always
    volumes:
      - "plume-data:/app/static/media"
      - "./plume.env:/app/.env"
      - "plume-searchidx:/app/search_index"
    labels:
      - "traefik.frontend.rule=Host:blog.picasoft.net"
      - "traefik.enable=true"
      - "traefik.port=7878"
    links:
      - plumedb:plumedb
    networks:
      - docker_default


