D
D
Dmitry2016-12-20 16:41:15
Yii
Dmitry, 2016-12-20 16:41:15

How to properly install composer on a remote server?

Good afternoon.
Tell me how to properly install composer on a remote server?
I tried to do this, following the instructions from google, but at the last step it gives out:


PHP Fatal error: Out of memory (allocated 107216896) (tried to allocate 96 bytes) in phar:///var/www/***********/data/www/******** /memory/composer.phar/src/Composer/Repository/ComposerRepository.php on line 566
Fatal error: Out of memory (allocated 107216896) (tried to allocate 96 bytes) in phar:///var/www/**** ****/data/www/*******/memory/composer.phar/src/Composer/Repository/ComposerRepository.php on line 566

Installed composer to the root of the project with the command
curl -sS https://getcomposer.org/installer | php -- --install-dir=/var/www/****/data/www/*****/yii2_adv

Did
php composer.phar install
everything went well. But when I try to update
php composer.phar update
, I get the error above.
Tried to do so
php -d memory_limit=512 composer.phar update
did not help.
How can the situation be corrected?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
Maxim Timofeev, 2016-12-23
@webinar

Similar composer errors are easily searched for by a search engine:
https://yandex.ru/search/?text=composer%20Out%20of...
Solution 1 - increase the limit. 512 is very small. Allocate 1gb minimum

D
Dmitry, 2016-12-23
@slo_nik Question

Tried and 1gb - the same result.
I was looking for errors and before writing here I tried to solve it myself. I changed the memory limit in different ways, in memory_limit I set the value to -1 ...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question