Member-only story

Symfony 4: deploying a new application with Heroku

Luís Nóbrega
4 min readAug 27, 2018

--

Symfony 4 and Heroku logos side by side

And after our application development is finished, and we have our first version, having slim controllers and fat services with Symfony 4, is time to release it to the world. I choose Heroku to that.

Heroku is a Cloud Platform as a Service that supports several languages.

Among them, theres support for PHP, as well as the Symfony framework.

I like to use it because, from the terminal I can manage the versioning of my code, as well as deploying the application. And Heroku itself, with configurations, automates everything related to infrastructure.

So in this article I will explain how to deploy an application in Symfony 4 in Heroku.

This article is based on official documentation, with some changes, as it has not been updated to version 4 of Symfony.

Step 1 — Create the Symfony Project

I assume that you already have a Symfony project created. If this is not the case, just follow the steps in this link.

Step 2 — Initializing a Git Project

In the project folder, simply execute the following commands.

Note: Before this initial commit do not forget to review your .gitignore. I did not, and…

--

--

Luís Nóbrega
Luís Nóbrega

Written by Luís Nóbrega

Web Developer at 25friday. Likes to travel, write and being a father.

Responses (5)