If like me you didn’t know, you can do that with Capistrano:

1 $ cap HOSTS=web0.myapp.com deploy:update_code
2 cap ROLES=web,app deploy

Not terribly useful for the tasks demonstrated above, but what about this ?

1 $ cap ROLES=app monit:summary

Incidentally, where are these documented ? I dimly remembered reading this somewhere once, and tried it. Works like a charm!

Even though Capistrano “tags” each release by creating a new folder on the production server(s), it might be interesting to have a historical perspective in your repository anyway.

This makes it easier to know exactly what went up for a release.

I would like to share the following Capistrano recipe for your pleasure:


1 require uri
2 task :after_deploy do
3 source = repository
4 dest = URI.parse(repository).merge("../releases/#{File.basename(release_path)}")
5 cmd = "svn copy —revision=#{revision} —quiet —message \"Auto tagging release #{release_path}\" #{source} #{dest}"
6 puts cmd
7 `#{cmd}`
8 end

First, we start by requiring uri, because Subversion does not like relative URLs.

Next, we find the location into which to tag the release, and finally, we just do it.

Simple, effective.

Enjoy !


Your Host

A picture of me

I am François Beausoleil, a Ruby on Rails and Scala developer. During the day, I work on Seevibes, a platform to measure social interactions related to TV shows. At night, I am interested many things. Read my biography.

Top Tags

Books I read and recommend


Projects I work on

Projects I worked on