How much of the Web build process do you/should you automate? *

Question

How much of the Web build process do you/should you automate?

And what is your system of choice?

Off the top of my head I would say that for a real one-step web 'build' the following steps would have take place:

  1. Take a source snapshot
  2. Change any config files for release
  3. Compress CSS and JavaScript
  4. Run tests
  5. Take a database snapshot (without test data)
  6. Move the source to the server
  7. Import a clean, current version of the database into the server
  8. Automatically confirm the 'build' was successful

Is there a system that does all of these steps?

Answer

Yes, in Ruby land we have Capistrano, which has "recipes" for executing shell scripts on your servers.

A typical recipe for deployment could to the following:

  • check out the latest version of the source code on your production server
  • have the web server direct all requests to a "upgrade in process" page
  • take the application server offline
  • point the current version to the latest version that you just checked out
  • update the database
  • restart the application server
  • "ping" the application server to make sure the cache is primed
  • point the web server at the app server

If anything goes wrong, it knows how to rollback to the previous version.

It's aimed at Ruby developers, but you could use it for any kind of Unix based deployment.

Also, whenever I check in source code to the server, the server automatically runs my tests, and sends me an email if any of them fail.

The Ruby and Ruby on Rails community are fanatical about automating things. E.g. there are also recipes for turning a clean Ubuntu install into a Ruby on Rails server with Apache, MySQL, source control, etc.

< br > via < a class="StackLink" href=" http://stackoverflow.com/questions/369/" >How much of the Web build process do you/should you automate?< /a>
Share on Google Plus

About Cinema Guy

This is a short description in the author block about the author. You edit it by entering text in the "Biographical Info" field in the user admin panel.
    Blogger Comment
    Facebook Comment

0 comments:

Post a Comment