The Reluctant Web Developer

Not a Wordpress site

Thoughts on Laracon Day 1

I'm at Laracon 2014 in NYC, and as I predicted, it's a little overwhelming - in Lower Manhattan, seeing in-person all of these people I've been following and learning from the last year or so, and listening to really smart people talk about stuff which, in some cases, is a little over my head. But it's all good, in spite of a few kinks with the venue.

enter image description here

I think I fully grasped/comprehended about 50% of the talks, which is fine. That's probably a better percentage than some design patterns books I've read the first time thru. Taylor Otwell's keynote was an exception in that I fully understand the headaches with dev environments and deployment, so Homestead and Forge providing the "artisan"-like bookends to developing with Laravel makes perfect sense. I hope that Forge can (eventually) work with existing VPS environments to some degree, as I don't deploy new environments often, but would love to use it for some existing VMs that don't use the hosting providers currently supported. enter image description here

Photo Credit:

Goodbye Wordpress, Hello "Brewski"

Since most of my work is "in-house" and won't ever reside on Github, and because needed to project that I would start using right away, and because Wordpress can be a PITA to work with at times, I decided to build my own Laravel-based blogging system.

It's still very rough, un-stable, and written by a hack (me), but it's now powering this site. Having a personal project that I'm using right away, and with the code exposed on Github, is a nice motivator to keep working on it - so after many false starts, I think I've finally found a personal project that will keep me interested for a while.

Heroku/PHP Quick Tip #1 – Webroot

So I checked out Heroku yesterday after the “official support for PHP” announcement. I pushed up a basic install of Laravel 4.1 to a new free account. However, if you just create your repo, set up Laravel, and do a

git push origin master

, your webroot will be the project root, not /public.

After reading about “buildpacks”, etc., I found out that all you need to do is create an empty file in the project root named “Procfile” and add

web: vendor/bin/heroku-php-apache2 public

to it (assuming you are using Apache).

I saw something else showing custom composer.json settings for heroku that defined the webroot, but I couldn’t get that to work.


Heroku/PHP Quick Tip #2 – Adding PHP extensions

If you are used to using Composer, adding PHP extensions to a Heroku PHP app is really easy. For adding the GD library, just add the extension as follows to the “require” section of your project’s composer.json file:

"require": {
"ext-gd": "*",
"laravel/framework": "4.1.28",
"doctrine/dbal": "2.4.2",
"guzzlehttp/guzzle": "4.0.2",
"way/generators": "2.6",
"fzaninotto/faker": "v1.3.0"

Heroku has a complete list of already included extensions and those available to be added during deployment.