One can imagine the decision process that has finally brought you here. It all started with you wanting to build a website or maybe a web application that sits on a server, whether it is a dedicated server, virtual private server (VPS) or cloud server. So you did your research on which server side programming language to choose from: Java, Python, Perl, PHP, Ruby and even ASP.net.
And so, after long consideration, you decided on PHP because of the cost effectiveness. It is free and open source, has a great community around it (which makes up for the lack of formal support due to it being open-source), it has a fairly easy learning curve, and comes with a lot of frameworks so the web application or website can be up and running in no time. And that’s not even to mention that most of the internet’s CMSes are built on it.
And once you made your mind on PHP, you explored all the ways of building websites or web applications in a quicker and more efficient way… and this brought you to an evaluation of frameworks.
A PHP Framework is a platform foundation from which developers can develop PHP web applications without needing to code every piece of functionality from scratch, or rewrite code repetitively every time a function calls for it. Frameworks allow for rapid application development (RAD). Thus, a framework can significantly reduce the development time for a web app to be built. And here again, within the PHP ecosystem you are spoilt for choice among the plethora of frameworks to choose from: CodeIgniter, Yii 2, Symfony, Laravel, CakePHP, Zend, and more, the list goes on and on.
Finally, after much research, you settled on Laravel. Despite being a fairly new kid on the block (released in 2011), it has slowly become a favourite among developers. Google’s 5-year trend shows that when compared to other frameworks like CodeIgniter, Zend, and Symfony (which Laravel is based on), Laravel has quickly overtaken all other PHP frameworks combined as a popular search term.
Pic 1. Laravel framework search trending on Google
It is no surprise Laravel has become the popular choice among PHP frameworks when it comes to building websites or web applications, it is famous for its ease use, as well as cost effectiveness when compared to other frameworks.
Additionally, Laravel supports Model-View-Controller (MVC) architecture. MVC is an architectural pattern commonly used for developing user interfaces that divides an application into three interconnected parts: model, view and controller. To briefly explain how an MVC process works, when a user sends a requests (example is retrieving data), the controller handles the request to be sent to the model and the model will then assemble the data and send it to be displayed to the user (view).
When adopting the MVC architecture this separation of concerns makes it easier for developers to update and refactor code (in the model, view and controller layers) independently with a lower chance of breaking the whole system. For some UI/UX developers, employing the MVC architecture gives the developer or designer more flexibility.
Pic 2: MVC Process
So there you have it, Laravel is basically a PHP framework that is aimed at helping developers to build web applications both in a short time and elegant manner.
Now that you know what Laravel is, maybe you need to decide on which control panel to use to easily manage the cloud hosting services that Laravel needs to sit on. RunCloud is a perfect choice to easily manage your PHP web sites that are being hosted either on cloud servers, virtual private servers (VPS) or dedicated servers. RunCloud is a clear winner when it comes to cost effectiveness when compared to similar service providers.
But if you need to know more, below are some points that are worth considering if you are still not sold on why you should use Laravel with RunCloud.
- Compared to ServerPilot, RunCloud has a more comprehensive control panel so you save time by automating tasks as well as reducing the need to constantly SSH to your server.
- CPanel and Plesk are more geared towards resellers so if you are just building a web app or a website, having a control panel with all the bells and whistles might be a bit overkill.
- As for Laravel Forge, even though it was created by the same creator as Laravel, it does not offer a support ticket system like RunCloud, where it only offers support through email.
So now comes the fun part: Deploying Laravel on your server with RunCloud!
If you are a developer, chances are you are using some sort of Git repository when building and testing your websites, as well as for version control. Good news! RunCloud supports Git deployment using GitHub, GitLab, Bitbucket, or custom Git Servers. So you can just deploy easily to your servers when you push your code to any of those repositories and RunCloud will deploy them using Git Webhooks.
Basically what you need to do is;
- Register with RunCloud here. You’ll get a taste of the Pro version for 5 days and if by the end of the 5-day trial period you wish to not subscribe to it, you will be automatically downgraded to the forever free version.
- Connect your RunCloud with your server: either VPS, cloud server or a dedicated server hosted by a provider. RunCloud will apply the optimised settings on your server so that you can just get back to coding instead of fiddling with the settings.
- Having said that, RunCloud still allows you to customize your server if you prefer it that way.
- In your RunCloud control panel, you can setup your web application, domain name, SSL, database, Git repository, and Git Webhook.
- Install Laravel on your development machine. Head on to the tutorial here to see how Git deployment and Laravel is made possible.
There you have it. Laravel makes it easy for you to develop websites or web apps in PHP and RunCloud keeps it just as easy to deploy and manage your web app on the cloud. Together, these tools are a valuable asset for a developer whose aim is to produce powerful web apps in a short time frame.