不确定这是否是ansible-galaxy中的错误,但我正在尝试从requirements.yml文件(相关的不可用文件)中安装角色。其中一个角色是从git中删除的,其中有一个特定的version,如下所示:
requirements.yml
---
- src: https://github.com/thom-nic/ansible-shell
name: thom-nic.shell
version: develop当我运行ansible-galaxy install时,我得到以下输出:
± ansible-galaxy install -r requirements.yml --force
- executing: git clone https://github.com/thom-nic/ansible-shell thom-nic.shell
- executing: git archive --prefix=thom-nic.shell/ --output=/var/folders/cw/9vh4w77n4vb_bchhsxnglrcm0000gn/T/tmpF4GAqD.tar develop
- command git archive --prefix=thom-nic.shell/ --output=/var/folders/cw/9vh4w77n4vb_bchhsxnglrcm0000gn/T/tmpF4GAqD.tar develop failed
in directory /var/folders/cw/9vh4w77n4vb_bchhsxnglrcm0000gn/T/tmpIyYaJz
- thom-nic.shell was NOT installed successfully.如果我将version更改为master,它就能工作。我在git中尝试过其他角色,结果也是一样的。
奇怪的是,ansible-galaxy本身似乎没有--version输出,但是ansible --version报告了v1.8.3。
发布于 2015-03-04 19:55:26
这是一个已知问题。同时,作为解决办法,修改requirements.yml中的版本,如下所示:
---
- src: https://github.com/thom-nic/ansible-shell
name: thom-nic.shell
version: remotes/origin/develophttps://stackoverflow.com/questions/28863504
复制相似问题