I really like the german hoster uberspace. They have a great setup, awesome documentation (only in german) and an amazing support team. This is a small introduction how you get your symfony project running on their system.
1 ) Composer
I found a great introduction how to get composer running on uberspace here. In short this are the steps:
$ nano ~/.profile
Add the following line:
$ source ~/.profile
$ curl -s https://getcomposer.org/installer | php -- --install-dir=bin
$ mv ~/bin/composer.phar ~/bin/composer
$ composer about
2 ) Git
I use Bitbucket for my projects as they offer unlimited private projects. For an easy deployment I create a own ssh key on uberspace and add it as a deployment key (repository settings) to the repository.
When it asks for a file in which to safe the key I enter “bitbucket”. You can set a password for the file.
Then create new file called “config” in the “.ssh” folder and add the following content:
Host bitbucket.orgIdentityFile ~/.ssh/bitbucket
Add the deployment key to the repository.
Clone the repository to uberspace (include the dot at the end):
$ git clone firstname.lastname@example.org:youruser/yourrepository.git .
3 ) Symfony
Install with composer:
$ composer install
Change document root:
$ ln -s /var/www/virtual/youruser/html/web/ /var/www/virtual/youruser/yourdomain.com
4 ) Move to production
Insert into /web/.htacess
Run the following commands:
$ php app/console cache:clear --env=prod --no-debug$ php app/console assets:install --symlink$ php app/console assetic:dump
Let’s run it