networks:
  1panel-network:
    external: true
services:
  qbittorrent:
    container_name: qbittorrent
    env_file:
    - ./envs/global.env
    environment:
    - PUID=0
    - PGID=0
    - UMASK=022
    - WEBUI_PORT=${PANEL_APP_PORT_HTTP}
    - TORRENTING_PORT=${PANEL_APP_PORT_TORRENTING}
    image: linuxserver/qbittorrent:5.0.3
    labels:
      createdBy: Apps
    network_mode: ${NETWORK_MODE}
    ports:
    - ${PANEL_APP_PORT_HTTP}
    - ${PANEL_APP_PORT_TORRENTING}
    - ${PANEL_APP_PORT_TORRENTING}/udp
    restart: always
    volumes:
    - ${QBITTORRENT_ROOT_PATH}/config:/config
    - ${QBITTORRENT_ROOT_PATH}/downloads:/downloads
    - ${CUSTOM_MOUNT_DIRECTORY_1:-./default_mount_1}:${CUSTOM_MOUNT_DIRECTORY_1:-/default_mount_1}
    - ${CUSTOM_MOUNT_DIRECTORY_2:-./default_mount_2}:${CUSTOM_MOUNT_DIRECTORY_2:-/default_mount_2}
    - ${CUSTOM_MOUNT_DIRECTORY_3:-./default_mount_3}:${CUSTOM_MOUNT_DIRECTORY_3:-/default_mount_3}
