David Rekowski's random stuff

Composer on uberspace


How can I install composer on uberspace?


symfony, composer, symfony2


I am going to install symfony on my uberspace account. To do so, I want to use composer as suggested on the symfony download page.

Prelude: personal bin folder

In order to have composer in the $PATH, I created a folder ~/bin and added it to my .profile file which I had to create (thankfully emacs is available by default).

$ mkdir ~/bin $ emacs ~/.profile # use nano or vi(m) if you prefer, even joe is available # add the following line export PATH=$PATH:~/bin # and reload the configuration (no need to logout/relogin) $ source ~/.profile # . ~/.profile would work as well

Installing composer

For some reason the first two attempts didn't work:

$ curl -s | php $ curl -s | php -- --install-dir=bin

Thus I used wget, which promptly complains about the certificate, which again means I need to do it like this:

$ wget --no-check-certificate

Now I run the installer and move it to ~/bin, omitting the .phar extension

$ php installer All settings correct for using Composer Downloading... Composer successfully installed to: /home/dave/composer.phar Use it: php composer.phar $ mv composer.phar ~/bin/composer

That's it. Composer is set up and can be run:

$ composer about Composer - Package Management for PHP Composer is a package manager tracking local dependencies of your projects and libraries. See for more information.

Continue with symfony

Next up: Install symfony on uberspace