1000 FAQs, 500 tutorials and explanatory videos. Here, there are only solutions!
Installing Composer on a Web host or a Cloud Server
Composer is an open source dependencies manager written in PHP.
It allows its users to register and install the libraries the main project needs.
Composer documents: https://getcomposer.org/doc/
- Log in to your host via SSH (Find out more)
- In the terminal, enter the following command: cd ~
- In the terminal, enter the following command: mkdir .composer
- In the terminal, enter the following command: curl -sS https://getcomposer.org/installer | php -d allow_url_fopen=On
- Composer is now available on your hosting
Launch Composer anywhere
It is not possible to install Composer globally on the server (shared / Cloud) nevertheless, once the above instructions have been followed, to execute the following command in SSH to launch Composer anywhere:
"folderComposer" is to be changed by the absolute path of composer (given during its installation).
If you wish to type "composer" instead of "composer.phar", you can rename the Composer file as follows, by placing yourself in SSH in the Composer folder:
For the change to remain after reconnectin in SSH, you must add it your profile, in SSH::
- create a .profile file if none exists: tap ~/.profile
- edit the .profile file:nano ~/.profile
- add the code to the interior of the file:: export PATH=$PATH:/folderComposer
- load the .profile file: sourrce ~/.profile