Can you create a working application in 15 minutes?
I believe that yes indeed you can do that. The questions are: How?
What are the downsides?.
The how is pretty much using right tools for the job. For most of my
projects it means this:
-Ruby on rails 3.1 +
-Ubuntu on a remote server
...and maybe a few more.
The mantra of design patterns is "Separate what changes from the
things that stay the same". So what should be the pattern for a quick
build script of a rails application?
Sure - you've got scaffolds, but I think they are not the answer to
all of the problems. In fact they don't help with most of the setup
tasks that you perform to create basic rails app.
Yeah, yeah - I know that with them I can build a blog in 15 minutes
but, seriously, I don't build blog engines that often.
Second solution from the top of my head - Rails templates, introduced
somewhere between rails 2.3 and rails 3
Little bit closer, but still not there. They are quite hard to
maintain, and not flexible enough. But certainly it's one step closer
to promised land of "convention over configuration".
The next thing - Rails apps composer gem.
Quite close to the holy grail of code generation. The way it works is
a two step process - first you generate your Rails template, and then
you create your application with standard Rails generators and a few
recipes which get executed in a specified order.
On our last hackday I was working on a recipe for automatic MySQL configuration:
But I think this is just the first step. I need one more recipe for
SendGrid and another one for Airbrake. Perhaps one or two more, for
Feedbackify and Facebook integration.
The next milestone in my opinion is automatic server configuration.
I'm not the greatest backend / server ninja, but I've done quite a few
Ubuntu and CentOS configs from scratch. In my experience, going from a
vanilla Linux distribution to a working deployed application takes
about one day of work.
I think that's way too long. And this is what my other collegues have
been working on during the hackday.
Expect another blog post about "5 minutes server provisioning" soon.