PhpStorm cannot find vendor/autoload.php on Docker WSL when running PHPUnit



PHP Snippet 1:

version: "3.7"

services:
  php:
    container_name: pkg
    image: my.private.registry/php7-cli:7.4.10
    volumes:
      - ./:/opt/project
    entrypoint: /bin/bash
    tty: true

PHP Snippet 2:

RUN curl -L https://squizlabs.github.io/PHP_CodeSniffer/phpcs.phar > /usr/local/bin/phpcs \
    && chmod +x /usr/local/bin/phpcs \
    && curl -L https://phar.phpunit.de/phpunit-9.5.phar > /usr/local/bin/phpunit \
    && chmod +x /usr/local/bin/phpunit \
    && curl -L https://phpmd.org/static/latest/phpmd.phar > /usr/local/bin/phpmd \
    && chmod +x /usr/local/bin/phpmd