由于Centos6上的GMP软件包版本,可能出现错误
我有一个Dockerfile,它基于由于Centos6上的GMP软件包版本,可能出现错误,centos,docker,centos6,gmp,ansible,Centos,Docker,Centos6,Gmp,Ansible,我有一个Dockerfile,它基于CentOS(标记:centos6)构建图像: 一切正常,直到Docker点击最后一行,然后我得到以下错误: [WARNING]: The version of gmp you have installed has a known issue regarding timing vulnerabilities when used with pycrypto. If possible, you should update it (ie. yum update g
CentOS
(标记:centos6
)构建图像:
一切正常,直到Docker点击最后一行,然后我得到以下错误:
[WARNING]: The version of gmp you have installed has a known issue regarding
timing vulnerabilities when used with pycrypto. If possible, you should update
it (ie. yum update gmp).
PLAY [all] ********************************************************************
GATHERING FACTS ***************************************************************
Traceback (most recent call last):
File "/usr/bin/ansible-playbook", line 317, in <module>
sys.exit(main(sys.argv[1:]))
File "/usr/bin/ansible-playbook", line 257, in main
pb.run()
File "/usr/lib/python2.6/site-packages/ansible/playbook/__init__.py", line 319, in run
if not self._run_play(play):
File "/usr/lib/python2.6/site-packages/ansible/playbook/__init__.py", line 620, in _run_play
self._do_setup_step(play)
File "/usr/lib/python2.6/site-packages/ansible/playbook/__init__.py", line 565, in _do_setup_step
accelerate_port=play.accelerate_port,
File "/usr/lib/python2.6/site-packages/ansible/runner/__init__.py", line 204, in __init__
cmd = subprocess.Popen(['ssh','-o','ControlPersist'], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
File "/usr/lib64/python2.6/subprocess.py", line 642, in __init__
errread, errwrite)
File "/usr/lib64/python2.6/subprocess.py", line 1234, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
Stderr from the command:
package epel-release-6-8.noarch is already installed
确保要添加到
/home/root/ansible
的目录中存在文件site.yml
和hosts
请注意,您可以使用WORKDIR
简化Dockerfile:
WORKDIR /home/root/ansible
RUN ansible-playbook -v -i hosts site.yml
对我来说,gmp似乎与问题无关。看起来
ssh
命令在我不存在的文件上失败了。我不确定在这种情况下该怎么办。我的Dockerfile
相当基本,因此它不应该真正阻止ssh连接不?这个问题似乎来自ansible playbook本身。ansible playbook要查找的地方是否存在该主机
文件?除此之外,一些更熟悉ansible的人(或者可能是docker,尽管我对此表示怀疑)需要加入进来。
- hosts: all
pre_tasks:
- shell: echo 'hello'
WORKDIR /home/root/ansible
RUN ansible-playbook -v -i hosts site.yml