version: "3.7"
services:
  qubic01:
    container_name: qubic01
    image: registry.cn-hangzhou.aliyuncs.com/dahaige/qubic:1.0
    networks:
      internal_network:
        ipv4_address: 172.30.0.1
    restart: always
    volumes:
      - /root/qubic-docker01:/qubic-docker
    command: bash /qubic-docker/run.sh
    cpuset: "0-47"

  qubic02:
    container_name: qubic02
    image: registry.cn-hangzhou.aliyuncs.com/dahaige/qubic:1.0
    networks:
      internal_network:
        ipv4_address: 172.30.0.2
    restart: always
    volumes:
      - /root/qubic-docker02:/qubic-docker
    command: bash /qubic-docker/run.sh
    cpuset: "48-95"

  qubic03:
    container_name: qubic03
    image: registry.cn-hangzhou.aliyuncs.com/dahaige/qubic:1.0
    networks:
      internal_network:
        ipv4_address: 172.30.0.3
    restart: always
    volumes:
      - /root/qubic-docker03:/qubic-docker
    command: bash /qubic-docker/run.sh
    cpuset: "96-143"

  qubic04:
    container_name: qubic04
    image: registry.cn-hangzhou.aliyuncs.com/dahaige/qubic:1.0
    networks:
      internal_network:
        ipv4_address: 172.30.0.4
    restart: always
    volumes:
      - /root/qubic-docker04:/qubic-docker
    command: bash /qubic-docker/run.sh
    cpuset: "144-191"

networks:
  internal_network:
    #enable_ipv6: true
    name: internal_network
    driver_opts:
      "com.docker.network.bridge.name": "br-proxy"
      #"com.docker.network.bridge.enable_ip_masquerade": "false"
    ipam:
      config:
        - subnet: 172.30.0.0/24
          gateway: 172.30.0.254
