[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fab-user] problem with host_string/hosts (no hosts found)
From: |
Wawrzek Niewodniczanski |
Subject: |
[Fab-user] problem with host_string/hosts (no hosts found) |
Date: |
Fri, 3 Oct 2014 10:37:08 +0100 |
Hi,
For quite a long time I've been using various fabric based scripts.
Recently I hit very strange problem. Following short script
illustrates my issue.
#!/usr/bin/env python
import fabric
from fabric.api import env, run
env.hosts = ['localhost']
def test():
print "Hosts:", env['hosts']
print "Host_string", env['host_string']
run('uname -a')
test()
And when I run It I got:
#>./fabric-min.py
Hosts: ['localhost']
Host_string None
No hosts found. Please specify (single) host string for connection: localhost
[localhost] run: uname -a
I copied content to fabfile.py and got the same:
#>fab test
Hosts: ['localhost']
Host_string None
No hosts found. Please specify (single) host string for connection: ^C
Stopped.
What do I do wrong?
I run my tests at Ubuntu 14.04 LTS with
Python 2.7.6
Fabric 1.8.2
Paramiko 1.10.1
Thanks,
Wawrzek
--
Dr Wawrzyniec Niewodniczański or Wawrzek for short
PhD in Quantum Chemistry & MSc in Molecular Engineering
WWW: http://wawrzek.name E-MAIL: address@hidden
Linux User #177124
- [Fab-user] problem with host_string/hosts (no hosts found),
Wawrzek Niewodniczanski <=