version: "3"
services:
  fe:
    image: 192.168.186.11:8033/cmii/doris.fe-amd64:2.1.6
    hostname: fe
    logging:
      driver: "json-file"
      options:
        max-size: "100m"
        max-file: "2"
    environment:
      - FE_SERVERS=fe1:172.21.80.2:9010
      - FE_ID=1
    ports:
      - 8030:8030
      - 9030:9030
    volumes:
      - /var/lib/docker/doris/doris-meta:/opt/apache-doris/fe/doris-meta
      - /var/lib/docker/doris/fe-log:/opt/apache-doris/fe/log
    networks:
      doris_net:
        ipv4_address: 172.21.80.2
  be:
    image: 192.168.186.11:8033/cmii/doris.be-amd64:2.1.6
    hostname: be
    logging:
      driver: "json-file"
      options:
        max-size: "100m"
        max-file: "2"
    environment:
      - FE_SERVERS=fe1:172.21.80.2:9010
      - BE_ADDR=172.21.80.3:9050
    ports:
      - 8040:8040
    volumes:
      - /var/lib/docker/doris/storage:/opt/apache-doris/be/storage
      - /var/lib/docker/doris/be-log:/opt/apache-doris/be/log
    depends_on:
      - fe
    networks:
      doris_net:
        ipv4_address: 172.21.80.3
networks:
  doris_net:
    ipam:
      config:
        - subnet: 172.21.80.0/24