version: "3.2" services: fail2ban: image: crazymax/fail2ban:${F2B_TAG:-latest} container_name: ${F2B_CONTAINER_NAME:-fail2ban} restart: ${SRV_RESTART:-unless-stopped} network_mode: "host" cap_add: - NET_ADMIN - NET_RAW volumes: - ${LOCAL_STACK_DIR}/data:/data - /var/log:/var/log:ro env_file: - "./fail2ban.env" environment: - TZ=${TZ}