Hacker News new | past | comments | ask | show | jobs | submit login
Laravel Forge – PHP Platforms On Linode, DigitalOcean, AWS, Rackspace (laravel.com)
216 points by uptown on May 19, 2014 | hide | past | web | favorite | 78 comments



Forge does the following for you:

  * API wrapper for many platforms
  * SSH-key only access (password access disabled)
  * Firewall management
  * CRON management
  * Sets up server dependencies and manages SSH keys
  * Handles private networking between servers and firewalls to open ports between them
  * Push to deploy (via Github)
  * Handles spinning up more queue workers (beanstalkd + supervisord) by clicking a button
  * Allows you to enter in "recipes" to run scripts (bash, php, others as well) on your servers
  * Allows you to "archive" servers - which means Forge will   "forget" your server, 
    eliminating the ability for Forge to access the server at all. 
    To re-enable the server from within Forge, you need to add  in a 
    new ssh public key which Forge will re-generate for you.
Forge is not:

  * Server management (if your server goes down, you contact the hosting, not Forge)


The need among PHP developers for a service that also does ongoing server management is why we built ServerPilot (https://serverpilot.io/).

While Forge is an advanced deployment tool similar to PuPHPet (https://puphpet.com/), ServerPilot is a modern alternative to cPanel for developers using their own servers.


From a quick look serverPilot looks really slick, and while I think I understand what you want to say, presenting it as:

> ServerPilot is a modern alternative to cPanel

Makes me want to kill it with fire. Lots of fire.

I suppose there are some lasting damage for becoming a sysadmin first and a developer second... ;-)


The other piece of this is Laravel Homestead (https://github.com/laravel/homestead), a Vagrant box to make local development easier. Through Forge, you can deploy basically the same environment Homestead provides to any of the services. It's an easier way of keeping your dev and prod environments the same.


I really like the direction that Taylor has taken with Laravel in the past few months (Laracon). The creation of both Homestead and Forge will allow new users of the framework to quickly get started and removes many of the pain points that a lot of us have when starting out with web development.

If someone looking to start using a framework asked me which they should pick, I would recommend Laravel in a heartbeat. It has a friendly, active community, amazing resources to learn from (Laracasts and many books/articles) and now with Homestead and Forge it should allow a new user to get up and running in a matter of minutes.


I guess it's worth noting that Linode and Rackspace can provide server management for you if sysadmin work isn't your forte.


what do you mean by this free, case by case basis, or a addon for additional fee? thanks


Signed up right away deployed a new server on Digital Ocean.

Really easy and powerful tool – BUT (this is a big one), why lock someone in with GitHub? Sure, GitHub is great. But what if I use BitBucket? Or even my own solution for my private projects?

This has killed many other services before for me, Pagoda Box (if I recall correctly) also forced someone to use GitHub, so did Appfog (or PHPfog rather).

I like Fortrabbits solution, where you at least can push your own code.


I think that Taylor mentioned in the keynote that BitBucket support is planned.

Edit: Confirmation of Bitbucket/Gitlab support coming soon: https://twitter.com/laravelphp/statuses/468401873519915008


If so – I'm very glad to hear that! Then there's hope for someone like me too.


Taylor has just mentioned on Twitter that he's going to start looking at Gitlab and Bitbucket tonight.


In the mean time you can use https://factor.io/ for "push-to-deploy" with BitBucket or Gitlab.


> so did Appfog (or PHPfog rather)

I never had to use GitHub for PHPFog. What do you mean exactly?


My bad – perhaps it was Engineyard? I know that there was one more service that I've tried besides PagodaBox on which you were "forced" to use GitHub to deploy code.


Yeah I seem to remember just being able to push directly?


You can push your own code on Forge... you have full server access.


I really like that this service allows the use of existing VPS providers instead of wrapping their service around one and charging a monthly premium. Unfortunately, PHP is one of the easiest to install, low-maintenance language platforms, so I don't know how much value they can add there, but give me something like Heroku that I can use with my own VPSs and I'll gladly pay you $10/month.


> something like Heroku that I can use with my own VPSs and I'll gladly pay you $10/month.

You could try something like Dokku, Docker powered mini-Heroku https://github.com/progrium/dokku If I am not wrong, DigitalOcean has dokku-installed images which you can just use within a few minutes.


Yeah, they do. Flynn (http://flynn.io) and Deis (http://deis.io/) are other popular choices, though Flynn is extremely new and difficult to get running properly, and it's not production ready. Deis is based on CoreOS now so it won't work on Digital Ocean at the moment if you prefer using them.


Yes, they do - and the setup is fairly easy. I made a guide for it on my blog: http://vancelucas.com/blog/using-dokku-to-deploy-php-applica...


Since it is just creating machines for you (i.e., it's created under your DigitalOcean account) can't you just stop paying for forge after you've created your servers, and keep using your DO account normally.


Well, you could. But you do get other features such easy management of env. variables, scheduling, New Relic monitoring and network handling.

Even if you are just running 2 sites, I really do think this is a great value for money ($10). If they only (as I wrote in my other comment) allowed for alternative ways to push your code.


I guess that some features like 'push to deploy' would not work anymore then.


For those that don't use Laravel, PuPHPet[0] is a great utility to generate local and deployable pre-made Vagrant boxes with a variety of apps. If you're interested in testing the Laravel Forge images locally, they use Homestead[1] which is the official Vagrant image for the Laravel Framework (as of 4.2)

[0] https://puphpet.com/

[1] http://laravel.com/docs/homestead?version=4.2


Problem with PuPHPet is that it's really buggy. I've used it more than 10 times (also recommended it to colleagues) and we managed to provision a box correctly maybe on two occasions.

Every time there was a different bug. Either something didn't install, or the config files weren't being loaded etc. I ended up learning Puppet because of it, so I guess some good has come of it ..


Sorry, it's just me trying to not break things :(

Slowly making it more and more stable, though.

If you now know puppet, maybe a PR or two would be on the horizon?


You do a great job, and you always help in IRC :) thanks for puphpet


I reported a couple of bugs and they were taken care of, actually. That said, I turned to PuPHPet specifically because I don't have time to tinker around.


For ruby there is https://www.cloud66.com/ and https://intercityup.com . Is there something also for python ?


I know this is an answer most people don't want to hear, but why not build your own Ansible / provisioning workflow and use that to do everything these services do?

I have one built in Ansible for our Python webapp and the entire configuration is encoded in the playbooks, rolling up the application into a source distribution, pip installing it, and also installing the dependencies...

Very easy, dependable, and extremely flexible.


Because solutions already exist like Cloud66 which means I don't have to learn Ansible. Having worked on deployment solutions for previous projects (using Capistrano), I was ridiculously relieved to discover Cloud66 and realize that I never have to think about provisioning and deployment again.


I think Laravel is a great framework. I just don't understand why the creator has to claim his ownership of the trademark "Laravel" on every page / documentation of the framework or anything that mentions the name. I mean Laravel is awesome, sure, but it's not some innovative piece of technology, like say the Linux kernel is. It is just another PHP framework with pretty features.


It's just another web framework, Coca-Cola is just another sugar water drink, Calvin and Hobbes is just another comic and a Lamborghini Aventador is just another car.

"Just another" is a really easy thing to say when it's someone else's creation. And more importantly trademarks are not indicators of quality or innovation. He's the owner and he chose to put it in the footer. This doesn't seem like a big deal.


I am really having a hard time seeing the value in this. All of the mentioned hosting services provide control panels that allow you to quickly provision a server. Running git pull from Github is pretty simple. I love Laravel and want to support Taylor but I'm just not seeing the benefit.


It's not simply provisioning the server. It's also installing all the relevant packages, configuration, and deployment. The value is toward people who don't have the sysadmin/devops skills (or perhaps time) to manage that themselves.


Are there not existing Chef/Puppet recipes that will do this for you?

I guess it gives you a nice web front-end, and maybe a bit of confidence that the configuration was designed by a professional?


Chef/Puppet are way too hefty for many small sites/devs. There are a lot of devs out there still setting up servers by hand who'd jump at something like Forge.


This is why I built Overcast. It's a CLI tool so there's no GUI, but I've tried to make it conceptually simple and possible to pick up right away:

    overcast digitalocean create my-app
    overcast run my-app install/core install/php install/apache install/mysql
http://andrewchilds.github.io/overcast/


Puppet provisions fine on an EC2 micro instance. It's no heftier than the software you'd want it to install to run your site anyways.


Hefty in learning curve, not system resources.


I created a FOSS project called PuPHPet[0] to help with the learning curve. So far it's been well received!

[0] https://puphpet.com


PuPHPet is a great project. It served as great "training wheels" for me while I was learning vagrant+puppet. Thanks for making it.


Ok, thank you for the explanation. I can see how this would be more helpful for people without as much experience.


I just downloaded and installed laravel yesterday. As a devops (more on the ops side) kind of guy, I was hoping for something simpler. I have a very basic PHP webapp I need to design with two or three user inputs. These inputs form a user-driven SQL query (AWS Redshift) and then generate html to create a graph (Google Charts).

I have a mockup in Balsamiq of how I want this to look. I also have a test query from PHP showing that I can connect to AWS Redshift. What I don't have is the PHP to render the user interface. Again, we are talking one text field, one three-way button and that's about it.

Anyone able to help point me in the right direction?

Thanks.


https://laracasts.com is a website run by Jeffrey Way formerly head of web development at TutsPlus and a brilliant teacher. He has a number of lessons available for free at https://laracasts.com/tags/free including a series of lessons taking you through most of the basics (https://laracasts.com/series/laravel-from-scratch/episodes/1).

It's only $9 a month which imo is great value. I'd take a look through the free lessons and if you like what you see sign up for a month or 2 and start building.

In addition to this Dayle Rees has an excellent book which can be found at https://leanpub.com/codebright which takes you through all the basic stuff and more. I personally prefer Laracasts as I am more video inclined and Jeffrey is an incredible teacher but they are both great resources.


Second laracasts, it pretty much sets the bar imo for content of that type, it would be worth 3 times the price (but no one tells him).

On top of which Jeffrey is just an all round nice guy (he does a bunch for the PHP community as well as some nice open source packages).


I don't think I'd use a framework for that use case. I'd pull in the AWS PHP SDK (amazing that we can use three sets of acronyms like that) via Composer, and then create a "quick script", if such a thing exists, to handle orchestrating all of that.

Rendering HTML isn't the highlight of Laravel (altho the template language is pretty nice)


I think the AWS angle is a bit of a canard in this situation. I'm a non-privileged user of the database just making simple read queries over SQL. The AWS SDK looks to solve problems I don't have.


Do you have experience in Rails? Honestly, Laravel just feels like "PHP on Rails" to me. It's a full framework like Rails, so it takes some getting used to. The Code Bright [1] tutorial was great for learning the syntax, and the Laravel documentation [2] helps during development

I'm not sure what your idea is, exactly, but once you get Laravel up and running it's fairly easy to do what it sounds like you're saying. Create a Model to interact with the database, create a controller for your routing, and then a couple of views for your form/success page/etc.

[1] http://daylerees.com/codebright [2] http://laravel.com/docs


The "Laravelesque" way to do this would be:

- POST route to a controller which calls a model which handles the database stuff, then redirects to..

- the GET route which calls a controller which calls a model which pulls from the database and returns a View which parses the result of the query into a template.

Although you could do it all inside the route closures as well if you wanted... I don't know how much extra overhead there is doing it one way versus the other.

If you want to use Laravel I might suggest picking up one of the starters you can find on github or reading up on MVC, it's really not that hard although it can seem complicated because Laravel puts so much effort into trying to cover every possible model.

Although, given what you're describing, Slim Framework with Twig and a simple class for SQL might be easier.


Depends on what "basic PHP" really mean. Modern PHP can be overwhelming for people from PHP4 / 5.0 eras.

I would (arbitrarily) reduce your choices to those two :

- Your project is not public and/or not likely to evolve much beyond the initial requirements : get Bootstrap and use a "basic" PHP script. You can already do a lot with raw PHP with the SPL (autoloader etc), filters (http://www.php.net/manual/en/book.filter.php), etc.

- If you need more, use a microframework like Silex or Flight. The learning curve will be steeper, but you'll also get more feature out of the box, if you need them.


Basic really referred more to the webapp than the PHP aspect. I could have been clearer. My point is, the application is not complex.


Does someone have a high level overview of how this works? The only route in is through signing up and i don't want to hand over my CC# just to see what's this about.


This preview was published after the announcement: http://mattstauffer.co/blog/getting-your-first-site-up-and-r...

Forge is essentially a platform that makes it very easy to provision a Laravel-ready server (though it states it works with other frameworks too). It's a replication of Laravel Homestead (http://laravel.com/docs/homestead) on a server, so you can have the same development and production environments.


Use digitalocean api to create servers and ssh into them to do stuff.


Nice !

This is going to make a big difference. For many, the setting up and launching part is a boring routine that they go through so often. I think the flat pricing model is the best part.


How are OS limits/configs (such as open file limits, connection limits, etc.) handled? Can these be specified in the web panel?


would be interested to test it before using, why not offer a free plan with 1 server max ?


I think that $10 is a reasonable bet to try out something that could save someone a lot of time and effort. Having a minimum helps weed out the casual tire-kickers. The people that pay the $10 to try it out _want_ to make this service work for them.


I sort of agree. This looks really interesting but there is a distinct lack of a demo or good walkthrough at least.


Perhaps you're not the target user then because if this service solved some of your pain points wouldn't you gladly pay $10 for a month of service just to try it out?

The upside is you found a service that saves you at least two hours per month. The downside is you're out $10.


I already signed up for it. But why not have some screenshots? I was speaking more from a marketing POV. Not necessarily for a free demo.


Is there something like this for rails? I am an okay bit-above-junior rails dev, but I can't deploy to anything other than heroku (and I cant find any good guides on learning to manage a server/deploy).


Deploying a rails app to a VPS (e.g. digital ocean or linode) isn't that much harder than setting up a development rails server on your work machine. If you have some time in the next few days for a screenshare I'll walk you through it - johnnybrown<%= prime_numbers[3] %>@gmail.com


Is there anything like this for Python / Django? I've come across similar service for Ruby / Rails but not Python yet..


heroku.com


Would this work for a wordpress site?


Probably so honestly. It's not super Laravel specific. I have installed ExpressionEngine on a Forge box in testing but haven't tried Wordpress.


Very cool. I'll have to try this out


It won't be really working that well for wordpress since it using nginx in stead of apache, so lots of rewrite thing need to configure for it.


Are there plans to support Softlayer?


Man, I wish this had a different name... it's going to be a hard sell saying "we should use this thing I found that sounds like 'larval' which is a word that means juvenile/immature".


Maybe we could suggest renaming it to bikeshed, then using the framework with the new name would be "bikeshedding".


That's not even remotely close to being the first thing that I think of when I learned about laravel.


Laravel is a widely used PHP framework.


I've had the misfortune of being forced to use Laravel on a project, and the larval connotations are pretty apt. Basically it's yet another PHP framework that adds megabytes of bloat to your application in order to give you alternate ways of doing things that are already trivial to do in PHP without providing anything that's actually helpful. Its one redeeming 'feature' is that they didn't go too far out of their way to make it incompatible with Composer, so once you work your way through Laraval's inane routing DSL (which, being built upon PHP, is a shitty DSL, and doesn't add any value over an if-else chain anyway) you can reference whatever libraries you need to get the job done without a lot of contortions. Even then, it throws good practice out the window by defaulting to throwing all the application-specific classes in the global namespace (which makes Composer's work harder, since it has to scan the entire app/ directory to build the class -> file map) and failing to provide any way to pass context to your code other than through global state.

Don't even get me started on the ubiquitous, ridiculously verbose, unhelpful, and intelligence-insulting comments. It's this kind of thing that makes me want to take up shooting sprees.


What's up with downvotes on my and TOGoS's comment? Critical comments are just as valuable as affirming comments.


Your's was a little pedantic honestly, but TOGoS was just insulting. Basically just trashing something he didn't like.

Ending it with "It's this kind of thing that makes me want to take up shooting spree" definitely confirmed that it was a pretty off-base and at least mildly inappropriate commentary.




Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact

Search: