2016-11-16 81 views
0

到現在爲止,我使用了Ansible的核心模塊。F5集成在ansible上

現在我會玩額外模塊。假設我想用我的劇本:bigip_partition。 我看到它在https://github.com/F5Networks/f5-ansible/tree/master/library

有人能告訴我如何安裝它們嗎? 我在Ubuntu 14LTS,Ansible 2.2

目前:

> sudo pip install bigsuds --upgrade pip 
> sudo pip install f5-sdk 
> sudo pip install git+https://github.com/F5Networks/f5-ansible.git -vvv 
Collecting git+https://github.com/F5Networks/f5-ansible.git 
    Cloning https://github.com/F5Networks/f5-ansible.git to /tmp/pip-NjrWJw-build 
    Running command git clone -q https://github.com/F5Networks/f5-ansible.git /tmp/pip-NjrWJw-build 
    Running setup.py (path:/tmp/pip-NjrWJw-build/setup.py) egg_info for package from git+https://github.com/F5Networks/f5-ansible.git 
    Running command python setup.py egg_info 
    Traceback (most recent call last): 
     File "<string>", line 1, in <module> 
    IOError: [Errno 2] No such file or directory: '/tmp/pip-NjrWJw-build/setup.py' 
Cleaning up... 
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-NjrWJw-build/ 
Exception information: 
Traceback (most recent call last): 
    File "/usr/local/lib/python2.7/dist-packages/pip/basecommand.py", line 215, in main 
    status = self.run(options, args) 
    File "/usr/local/lib/python2.7/dist-packages/pip/commands/install.py", line 335, in run 
    wb.build(autobuilding=True) 
    File "/usr/local/lib/python2.7/dist-packages/pip/wheel.py", line 749, in build 
    self.requirement_set.prepare_files(self.finder) 
    File "/usr/local/lib/python2.7/dist-packages/pip/req/req_set.py", line 380, in prepare_files 
    ignore_dependencies=self.ignore_dependencies)) 
    File "/usr/local/lib/python2.7/dist-packages/pip/req/req_set.py", line 634, in _prepare_file 
    abstract_dist.prep_for_dist() 
    File "/usr/local/lib/python2.7/dist-packages/pip/req/req_set.py", line 129, in prep_for_dist 
    self.req_to_install.run_egg_info() 
    File "/usr/local/lib/python2.7/dist-packages/pip/req/req_install.py", line 439, in run_egg_info 
    command_desc='python setup.py egg_info') 
    File "/usr/local/lib/python2.7/dist-packages/pip/utils/__init__.py", line 707, in call_subprocess 
    % (command_desc, proc.returncode, cwd)) 
InstallationError: Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-NjrWJw-build/ 

感謝, 裏卡多

回答

3

https://github.com/F5Networks/f5-ansible不是一個Python包,不要試圖用PIP安裝。
要使用這些模塊,你只需要將從library到python文件playbook-path/library