I got this error when running composer.phar update on my VM:
composer.phar update
PHP Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried t
The only thing that solve my problem was doing this:
/bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024 /sbin/mkswap /var/swap.1 /sbin/swapon /var/swap.1
REF: COMPOSER TROUBLESHOOTING