Greetings,
When I first got Flarum I had an OP server which made using commands via terminal a breeze. Using simply the commands, composer require <plugin_name>. It'd be done in a matter of seconds, however, unfortunately when I moved over to a different host. I was bombarded with failure to allocate memory or got stuck on the installation which never completed.
Managed to find a fix based on a guide posted by, Inmotion Hosting. My brother showed me how to fix this for I'm not the smartest cookie but I'm not that dumb either. We fixed the problem by modifying the php.ini file.
Install process:
`Flarum Extension Installation guide:
cd flarum
php -c /home/vanilla/flarum/public/php.ini /opt/cpanel/composer/bin/composer require <plugin name>
(example php -c /home/vanilla/flarum/public/php.ini /opt/cpanel/composer/bin/composer require matteocontrini/flarum-imgur-upload )
Ran via Terminal or SSH`
The source: https://www.inmotionhosting.com/support/website/use-website-php-ini-with-composer/