There are quite a few resource available on how to run Laravel on Heroku, but most of them only demonstrate the basics. When moving a fairly complex and big Laravel project to a Heroku infrastructure, you are bound to run into some problems.
To tell Heroku to load extra PHP modules into apache, you need to add them to your composer.json ‘require’ element: The basics are set: we know how to push our local development branch to Heroku, and how to build and release our app.
So I opted for that; and it’s quite simple to switch: For me, the transition to PGSQL was flawless, but if you run into issues I’d love to hear and add solutions to this article.
One of the key characteristics of the Heroku platform is that a Dyno (which is the instance that is executing your Laravel code) has a local filesystem that you cannot rely on to keep your files.