I have in the same server in 2 differents directories, like this:
- /var/www/pre.myproject.com/
- /var/www/myproject.com/
pre.myproject.com is a full copy from production myproject.com
When I am trying to run the command composer install inside the folder /var/www/pre.myproject.com/ with this:
composer install --no-dev --optimize-autoloader
I see the following errors:
Cannot create cache directory /var/www/myproject.com/.composer/cache/repo/https---packagist.org/, or directory is not writable. Proceeding without cache
Cannot create cache directory /var/www/myproject.com/.composer/cache/files/, or directory is not writable.Proceeding without cache
Why is it trying to make changes in myproject.com if I am currently at pre.myproject.com?
What files should I change in my folder pre.myproject.com to enable a new environment in Symfony3? And so the composer can install correctly for this environment and within this directory?
What you trying to do is having a new installation of an existing Symfony project with an existing
composer.jsonfile containing all your dependencies.What you should do is not
composer installbutcomposer updateas the composer.json file should already exist, it'll just read it and download the dependencies packagescomposer update:This is what I am using on my
productionserver when I import a new feature from mydevelopmentbranch.Edit
You should add
--no-cacheoption to bypass the cache.