Laravel on Host Monster Shared Hosting
Aug 14, 2013
0 Comments
Steps that I needed to follow to get this Laravel site working on Host Monster. I had the site working on my local machine and checked into Git on BitBucket.
- Setup an SSH Key on the Host Monster server to connect to my BitBucket account.
- Clone the git repository from BitBucket into the ~/wisemanta directory.
- Move ~/public_html to ~/public_html_backup. This keeps a backup of the old web content.
- Create a soft link from ~/public-html to the Laravel public directory: ln -s wisemanta/public public_html. This makes the public directory in ~/wisemanta the directory that the web server serves up.
- Update PHP to 5.3 on Host Monster. Mine was on 5.2.
- Download Composer
- Figure out that I need to run php-cli from the command line rather than php to run composer. Add alias php="php-cli"' to .bashrc to allow php to work in the future.
- Run install from composer: php composer.phar install. If you try using php without the alias to php-cli then the install would bomb out on the post scripts (which call php directly).
- Create the new database and database user.
- Run the Artisan install scripts: php artisan app:install
- Update public/.htaccess with this line:
- AddType application/x-httpd-php53 .php
- Waste two hours figuring out why I was getting a "ReflectionException Class FrontEndController does not exist". Turns out that my class filename was FrontendController (lower case e) which worked fine in Windows but not so much in Unix.
With that I was able to get this Laravel site running successfully.
There is still one error I am getting when running Composer. Things seem to be working, so I have been ignoring it at the moment, but if anyone knows what is causing it let me know. Error message:
[Symfony\Component\Process\Exception\RuntimeException] The process has been signaled with signal "11".