It's a control panel to manage your apps, databases, and other server bits
Digital Ocean is a bare server, it comes with nothing except the os you choose when setting it up.
Forge, makes the rest of the set up easy and has integrated deployment from your git repo.
Have you looked into Forge? Just started using it (with AWS) recently after self-hosting (own hardware) for years. I am really enjoying the conveniences it brings. It’s not for everyone / everything but worth a look for sure. Good luck!
> Server Security > > Subscriber is solely responsible for maintaining the security of Subscriber's servers that are created via the Laravel Forge service. Laravel Forge shall have no liability for any security breaches or data breaches of Subscriber's servers, even if those servers were initially created and provisioned by Laravel Forge. Laravel Forge does not gurantee the security of any of Subscriber's servers, even if those servers were initially created and provisioned by Laravel Forge.
If you need higher levels of assurance that your server is secure, you will probably need to provision and deploy your environment itself and bring further control of the systems into your sphere of responsibility.
Vultr offer some of the cheapest VPS and Forge supports them.
$50 free https://www.vultr.com/?ref=8065856-4F (I get $25 credit but that is not why I am recommending them)
Is this what you want ?
Mac only tho :-/
It uses the forge api
On the why does it needs to be web hosted, Saas are easier to market than desktop app, and taylor is probably less used to more desktop oriented languages.
Also I wonder what is the disadvantage of being web based. You would need an internet connection to setup servers anyway.
This quicker release cycle, and the fact I had to upgrade several projects from 4.2 to 5.0, is why I created Laravel Shift.
While I understand the lure of LTS from an "enterprise" perspective, I wrote a while back I considered LTS a trap.
By letting your projects sit, you are acquiring technical debt. Debt which has a high, compound interest rate. That is each version puts you farther and farther behind.
Between the Upgrade Guide and Shift you have the resources to keep your projects up-to-date.
For those pointing to clients or hosting concerns, I see this as all the more reason to upgrade. You clients need to be aware they are running an insecure piece of software on outdated servers. Better yet, use Shift + Forge to make keeping your Laravel projects running the latest version super simple.
If they choose not to keep up-to-date, you should pass the cost of the technical debt through to them. In fact, regardless of if you use a service like Shift, you should always pass the full cost to upgrade projects through to a client.
Hi! Creator of puphpet here.
Laravel Homestead is a fine solution if its choices suit you. What I mean by this is that LH comes with a few choices already made up for you. Per its docs, they are:
If this list matches your requirements perfectly, then great! Use it. Of course if you want to deploy this exact configuration, you'll probably end up using Laravel Forge which is not free.
On the other hand, PuPHPet comes with a bit more freedom:
There's many, many more differences, but these are the most obvious. Enjoy!
Don't forget about Laravel Forge. I think that would be the preferred laravel way of doing things.
It's compatible with Digital Ocean, and comes with its own control panel to allow you to easily deploy, setup new hosts, and so on.
It'll put you back $10 per month, though. But for the amount of administration time that it can save you, it might be worth it.
Code changes can be released with filezilla. You can just YouTube for filezilla how to use, but did u add any new database migrations ? That will require you to run artisan migrate. I would opt you to use Envoyr or Laravel forge. It's cheap for a single website imo
https://laracasts.com/series/envoyer https://forge.laravel.com/
I'd disagree with the specific mention of forgetting Laravel, but I will agree that it feels like you're a little in over your head already.
I'd skip trying to manage your DigitalOcean service yourself if I was you, and go with Laravel Forge (https://forge.laravel.com/). You'll still need a DigitalOcean account, and while that's extra cost, Forge will handle 99% of what you're after for you.
Baby steps are important, and it very much feels like you're trying to run before you can walk. Take the time to learn what it is you need to do before you start throwing yourself in. There is a reason there is a whole role (SysAdmin / Network Admin) for this kind of stuff, it's not just a "bolt on" to Web Development.
As I said, invest in Forge, let that do the heavy lifting for you so you can focus on building your application.
What are you building?
From HN:
> I've actually been really impressed with Laravel after switching back to PHP for a few projects. Not only is the developer tooling experience some of the best I've experienced, it's just really the only framework I've ever experienced with a high quality ecosystem of tools—from Forge[1], which makes it dead-simple to deploy a Laravel app into production to things like Horizon, for managing Redis queues.
> A great example of this in action is Laravel Spark[3], a first party base for building paid SaaS apps. I built and launched a writing tool, Write Together[2], to the world in under three weeks, payment systems and all, and got 150 paying customers in a matter of a few weeks. One hell of a great way to MVP an idea and build something useful, in a low amount of time.
> I'm basically developing two Laravel apps full-time at the moment, and it's the most fun I've had in years...compared to the hellscape of NPM dependencies and other complexities I'm usually bogged down with. Composer, the package distribution system, really needs work and is incredibly slow, but other than that—I'm really happy.
I use FORGE from Laravel. It handles adding domains, all SSH, and so much more. It's $10 - $19 a month depending on your needs and connects directly with Digital Ocean and more.
​
Normally shared hosting is pretty locked down to where things go and what is installed etc.
So yes - It can be abit hackery to get a Laravel install running on shared hosting (Not sure if some have support for Laravel out there).
​
An alternative could be to use part of the Laravel eco-system to setup your VPS for you - Check out Laravel Forge.
This will atleast get you setup with some pretty decent defaults for your VPS.
​
If you are getting in to running your first VPS please be sure to read some guides on securing it after setup, things like ensure users have password set, no root access via SSH, SSH key only access.
One such guide could be this one from Digitalocean.
​
Good luck whatever you end up picking.
Simple, create your servers in Forge to server your application, in your env config you set the db to connect to your remote AWS RDS MariaDB server for each of them.
You can SSH into each server and do what you need OR create a recipe in forge (https://forge.laravel.com/recipes) to do what you need and run it on your servers.
I'm not sure if you can exclude MySQL when initiating a server but you certainly can just not use it or use your custom recipe to disable/remove it.
Forge is also made by taylor otwell, and has git deployment. Envoyer has 0 downtime deployment, but for most people the downtime on a forge deploy is not even going to be noticeable.
I actually really like forge. It will connect to digital ocean / linode / aws via api and build and configure your server for you as well. You get unlimited sites on the $10 a month plan.
Eloquent: It's up to you if you want to use Eloquent, or just use raw MySQL queries from what you already have. If you have a ton of queries, it might be a lot of work. If there aren't too many, I say it wouldn't hurt to learn how to use Eloquent.
AngularJS: Angular might be overkill if your only goal is fancy front end eye candy. If that's all you need, I find that bootstrap and some jQuery plugins will suffice. Maybe even some help from some css animation libraries like animate.css. Nonetheless, if you do want to use Angular with Laravel, that can work too.
Deploying: Shared hosting with Laravel can work but will probably be a huge pain in the ass and won't be easy. Most people would recommend using a VPS like DigitalOcean, Linode or AWS. Laravel Forge makes this process easier if you don't know too much about server admin, but it's a paid service (great IMO).
Best Practices: Good on you for wanting to improve on your code base and architecture. That in itself says a lot. In MVC best practices, the view shouldn't contain any logic outside of displaying data. It might have some logic for filtering which data to display, which can be further extracted using view presenters.
Do yourself a favour and get a subscription to Laracasts. There are TONS of screencasts on all the topics you asked questions about and then some.
Hope this helps :)
I didn't watch the video but after having played around with setting up Laravel on Amazon EC2 via Forge (https://forge.laravel.com/) I realised with forge you can also really easily just launch a new Wordpress website. I highly recommend you look into a combo of Amazon EC2 and forge, I now have a lovely system that all works via my github, I just push a button to update from my latest repository.
I host it on my own DigitalOcean Server; together with other side projects.
Firefly is written in PHP and the Laravel framework. I write Laravel apps for my job too. To make it easier to deploy them, I use Laravel Forge. Forge creates and configures the server to make it super easy to deploy those PHP apps.
I have a Raspberry at home too, but never tried installing Firefly on it. Would probably work with Docker? Found this tutorial on how to install Firefly with Docker: https://dbtechreviews.com/2020/08/firefly-iii-installed-on-docker-self-hosted-personal-finance/
(I personally don't have a problem, that the app is theoretically public to the internet. I even use this to write little iOS Shortcuts to make it easier to add transactions)
I'm certainly not an expert here, but I think databases run best when they can be loaded into memory. So for those base level instances ($5 droplet, or whatever Google offers) where they give you a 1gb of ram, then a smallish app for 100 people should be more than sufficient.
I haven't had any experience with the Google cloud, but when you compare Digital Ocean to Azure and AWS, from memory, DO is about 50% cheaper.
Now that I'm not on my phone, Laravel Forge was what I was actually thinking of! $12 a month and it manages the server for you - I've never used it before, but it's another tool you can consider if you are hesitant about server management.
Make a Digital Ocean account. Sign up for a Laravel Forge account.
Then you hook your DO account up to forge and create a new server and site it will provision a server for you. Then install your app and hook up a domain.
Unless you have opened up port 3306 (I don’t recommend doing this) you will be required to use an ssh tunnel and access the database via localhost once connected. Check out this for more info on adding public keys to a server deployed with forge.
I use forge.laravel.com it helps you out a lot with getting the right setting for prod. There are quite a few things you can do. Obviously the two lines above are not for prod envs.
You would also want to enable caching and make sure your databse can't be accessed by others. I also mod the firewalls to only allow my ip access to the ssh ports, so there isn't the constant barage of idots trying to ssh into your server, it blows out the logs.
​
Pay for forge for a month, learn from it. If you can afford to keep it do that, if not replicate it.
Digital Ocean encrypts traffic at the network level in their infrastructure, so then local machine level firewalls handle the access via IPs/Ports. Services like Forge (https://forge.laravel.com/) make it easy to setup.
If you want to deploy to production fast, you can go with Laravel Forge or Laravel Vapor, depending on your needs.
If you want to check your development environment, you can go for php artisan serve
and then open your browser in http://localhost
.
BTW, "deployment" is a word mostly referred to pushing your application to production (or a live server, with real users).
Unfortunately, for many people:
In work environments like this - I would highly encourage you introduce changes gradually.
This often means having a clear path on how to use new tech and a fast + easy way to show it's benefits.
For example: version control.
After dealing with similar issues, I decided to ditch Laradock.io and just use Laravel Forge. Laradock is great for what it is but I just found my self spending more time configuring and hoping that things don’t break.
Forge is worth every penny because I get to get back to developing instead of trying to get everything to work well. Deployments are literally painless plus, I’m using less CPU than I was with Laradock.
Hope this helps.
Not to be a shill or anything, but this is exactly what forge.laravel.com is made for. Trust me, it is WORTH THE MONEY. I can, and have, configured manually about 40 servers, and I wish I could have used it. For all my personal, and NOW my professional projects, we use forge.
if you are happy with laravel, i recommend https://forge.laravel.com/ .
It's kind of bad to restrict yourself to one ecosystem, and since forge is pretty magic, you won't be learning so much about servers. But if you don't care about setting your own server etc. forge is way to go.
My current process:
Use https://forge.laravel.com/ to build a server on https://www.digitalocean.com/
If you need to be able to deploy upgrades with zero downtime https://envoyer.io/
Forge and Envoyer are built and run by Taylor Otwell who created Laravel so paying for those supports the development of Laravel
Personally I wouldn’t try and deploy on shared hosting.
Take a moment to figure out what you're doing lest your server inevitably get hacked and recruited into an evergrowing botnet. You might want to look into a solution like Forge, since it's a PHP project. You've got a long way to go to use a VPS responsibly. I suggest you get started by going through some simple tutorials, because every indication at this stage is that your server won't end well.
Hi,
For provisioning/configuring the server you have different options, like using Laravel Forge or existing provisioning tools like Chef/Puppet/Ansible. I guess I have to also promote my Ansible playbooks designed for Laravel apps. For deployment there are tons of options. Deployer, Rocketeer and Capistrano to name a few. I've been quite happy with Deployer. It includes a basic recipe for Laravel. Below is an example deploy.php and I just deploy simply by running "dep deploy production". If you mind paying for SaaS and are not interested learning new tools, I probably would go with Forge as it also provides git push deployments.
<?php namespace Deployer;
require 'recipe/laravel.php'; require 'vendor/deployer/recipes/recipe/cachetool.php';
// Configuration set('repository', ':repo/project.git');
// Servers host('server.somewhere.com') ->user('root') ->identityFile('~/.ssh/id_rsa') ->set('deploy_path', '/var/www/project') // Define base path to deploy you project. ->stage('production');
after('artisan:optimize', 'artisan:migrate'); after('artisan:optimize', 'artisan:db:seed'); after('deploy:symlink', 'cachetool:clear:opcache');
Although I host my sites on a dedicated server (I know quite overkill). A good way to go about it is using DigitalOcean and then you can manage sites and servers with Laravel Forge. You probably will require some knowledge on Linux commands
Laravel Forge (https://forge.laravel.com) might fit your needs. Links with your DigitalOcean, Linode, or AWS account and gets you the latest PHP, Nginx, etc. all installed, push to deploy, etc.
We have a preset for Symfony apps when you install a site so that Nginx is properly configured for Symfony.
+1 but my mixture is DigitalOcean + forge + Envoyer (or just DO & Forge if you want, Envoyer is just really useful ontop of the stack for zero downtime deployments & monitoring).
Typically, I deploy using git. In my opinion, probably the easiest way to do this is with continuous integration. There are plenty of ways to manage this. Codeship lets you set up hooks on bitbucket or github, and when it detects a push on the branch that you are watching, it can be configured to run unit tests, and then log in to your server and deploy.
As far as I can gather Laravel Forge does pretty much the same thing, and it might be worth playing with if you develop locally using homestead.
Deploying using ftp is getting rarer and rarer these days from what I see.
> ServerPilot.io
I recommend checking out Laravel Forge to use with DigitalOcean. And then you can always take it a step further and get Envoyer for zero downtime and some more functionality.
Loving this setup, switched over from Heroku a few months ago in favor of this.
I'm hosting all my clients on it for I have great control and billing flexibility over servers. Though I use Linode for database stuff because it has proven faster for some NoSQL works in my experience. Plus I've started deploying with Laravel Forge and we went batshit crazy with my associate. It use server app-keys so you can manipulate them thus semi-automating pretty much all the work that needs to be done with servers remotly. -> https://forge.laravel.com/. We scale apps real quick through this setup. It's quite nice as we've had shitty client hosts for a while now we make use of Digital Ocean almost mandatory in our contracts.
You haven't spoke about money so I guess you can spend an extra few coins. My suggestion is get on with laravel forge setup cheap vps install with all dependencies already installed regarding node.js and you're good to go. https://forge.laravel.com/ https://www.digitalocean.com/features/one-click-apps/node-js/ This way you'll have server / db management on the fly with GUI and won't bother to figure out dev environment setup. BTW : if you go for postgreSQL stuff you'd rather go with linode instead of digital ocean in my opinion.
There are a few different ways to do it.
There are services like Laravel Forge that will monitor any changes to a Github repository and automatically pull any updates to your live production codebase without you having to do anything on the production-server side.
The more common way when using a service like AWS or something that allows ssh access is to push to a Github repository from your local computer, and then ssh into your live production server and use "git pull" from your code's home directory. Its a few more steps than the first option but services like Forge usually only work with certain types of hosting providers. But this "push-pull" method will work on any hosting provider that allows ssh access. And yes, this would all be done in terminal.
Different versions on different environments is super easy with Git. Once you get the hang of branches, you can simply use the git checkout branch feature which will instantly change all of your code to a specific branch. Lets say you were adding a new feature and coding it on your local computer. You could make a new branch called "new-feature" or something, code up that feature, and test it on your local environment. All the while, your production code will still be running on the "master" branch, so any of your changes made in "new feature" branch wont apply until you merge the two.
Open the Nginx config up (through forge even) and remove the 3 lines regarding SSL.
https://forge.laravel.com/servers/[server]/sites/[site] -> edit icon (bottom right).
ssl on; ssl_certificate /etc/nginx/ssl/[site]/[arb number]/server.crt; ssl_certificate_key /etc/nginx/ssl/[site]/[arb number]/server.key;