Jeff Forcier wrote: > First, set/get is now simply attribute setting/getting of a global > 'config' object. Secondly, you can use a @hosts decorator to set a
I am sorry, I did not make my use pattern clear. I am *importing* fabric
into my own script. I am not using fab, and I don't have a fabfile.
In [1]: import fabric
In [2]: fabric.config
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
.../<ipython console> in <module>()
AttributeError: 'module' object has no attribute 'config'
In [3]: fabric.let
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
.../<ipython console> in <module>()
AttributeError: 'module' object has no attribute 'let'
Replacing the loop internals here:
>> for hostname in ['host-a', 'host-b']:
>> fabric.set(fab_hosts=[hostname], fab_user=username,
>> fab_password=password, fab_fail='abort')
>> fabric.run('uname -a')
with:
@fabric.hosts(hostname)
def foobar():
fabric.run('uname -a')
foobar()
does not work either:
Traceback (most recent call last):
File "s.py", line 15, in main
foobar()
File "s.py", line 13, in foobar
fabric.run('uname -a')
File "build/bdist.linux-x86_64/egg/fabric.py", line 163, in wrapper
KeyError: 'fab_local_mode'
--
Heikki Toivonen
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Fab-user mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/fab-user
