fab-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Fab-user] grouping tasks


From: Jiri Barton
Subject: [Fab-user] grouping tasks
Date: Fri, 29 Jan 2010 15:54:45 +0100
User-agent: Thunderbird 2.0.0.23 (X11/20090817)

Hi,

I was wondering if there is a way to group tasks and then refer to the
group by one name. I don't want to start but sort of what namespaces in
Capistrano could be used for.

What I'm trying to do is to deploy to several machines which are domain
specific. I have a database machine, a web server with the application
code, a machine which runs daemons, and a machine for command queuing.
Of course, each machine has specific needs and it would be more fitting
if I defined different fabric tasks for each of them, like:

def deploy_db():
    #migrate the db schema

def deploy_app():
    #restart web server

def deploy_daemons():
    #restart all app daemons

def deploy_queue():
    #restart the queuing manager

Now, what I have to do is

fab deploy_db deploy_app deploy_daemons deploy_queue

What I had rather do is

fab deploy

This would call those four tasks from above.


The reason for that is the deployment plan - the order in which the
deployment tasks are run - hardly ever changes but the order of the
tasks is essential. Sometimes I need to restart some services on other
machines and so this deployment plan changes.

Is there a way?

Thanks
Jiri







reply via email to

[Prev in Thread] Current Thread [Next in Thread]