fab-user
[Top][All Lists]
Advanced

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

Re: [Fab-user] Better way?


From: Jordi Funollet
Subject: Re: [Fab-user] Better way?
Date: Mon, 1 Jun 2009 21:01:49 +0200
User-agent: KMail/1.11.2 (Linux/2.6.28-11-generic; KDE/4.2.2; x86_64; ; )

Curt Micol dixit:
> I am finding myself writing stuff like this: http://dpaste.com/48936/
> when writing "controls" for programs.  Is there a better way to do
> this?  Nothing is coming to mind.  It isn't that I don't like this
> method, it's that I'd like to see what other people are doing.
>
> I have something like this for Virtuozzo and Xen also. Which reminds
> me, we need to get a fabfile focused site up. :)
>
> Thanks for any suggestions,

Hi Curt,

I like Fabric for more-or-less elaborated scripts, but I keep using 'dsh' for 
the cases you show that are one-liners. The classic:

  $ dsh -g webservers -- /etc/init.d/puppet restart

'dsh' lets you create a hostgroup in a file (here, ~/.dsh/groups/webservers). 
This and the 'bash' history makes really fast to run simple commands. Much 
faster that editing the 'fabfile.py' and adding another command.

Actually, I'm using Fabric as the tool for anything too complex for 'dsh' and 
that I don't want into Puppet.

But this is a feature I would like to see in Fabric: the ability to run a 
quick command from the command-line.

  $ fabric --role appservers -- /etc/init.d/puppet restart

This would cover the things I'm doing with 'dsh' right now.
-- 
##############################
### Jordi Funollet
### http://www.terraquis.net





reply via email to

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