Moving "vendor/" in a different location and symlinking it breaks drush I'd like to have vendor/ moved out of the Drupal 8 root and symlink it. Composer doesn't have any problem with that (all commands work) but when I issue any drush command, even drush --version, it breaks.

Steps to reproduce:

$ composer create-project drupal-composer/drupal-project:8.x-dev website --stability dev --no-interaction --prefer-dist
$ cd website
$ mv vendor ..
$ ln -s ../vendor vendor
$ drush --version

PHP Warning:  require(/tmp/test1/vendor/composer/../../load.environment.php): failed to open stream: No such file or directory in /tmp/test1/vendor/composer/autoload_real.php on line 70
PHP Fatal error:  require(): Failed opening required '/tmp/test1/vendor/composer/../../load.environment.php' (include_path='/tmp/test1/vendor/pear/archive_tar:/tmp/test1/vendor/pear/console_getopt:/tmp/test1/vendor/pear/pear-core-minimal/src:/tmp/test1/vendor/pear/pear_exception:.:/usr/share/php') in /tmp/test1/vendor/composer/autoload_real.php on line 70


Full log: https://pastebin.com/raw/eMDgkdHV

Can I achieve this somehow? Even if I need to temporarily edit some path in an autoloader php script.

I need to do this on the vagrant based dev environment where I'd like to pull vendor/ out of the synced folder which is very very slow.
I managed to solve it via specifying an absolute path in the vendor-dir configuration of composer.json: https://getcomposer.org/doc/06-config.md#vendor-dir