Kolla-ansible openstack: Docker version failure

环境:ubuntu16.04

我在kolla-ansible部署q版oopenstack执行如下命令时报了错误

kolla-ansible -i ./all-in-one prechecks

fatal: [localhost]: FAILED! => {"msg": "The conditional check 'result | failed or result.stdout | regex_replace('.(\\d+\\.\\d+\\.\\d+).', '\\1') | version_compare(docker_version_min, '<')' failed. The error was: template error while templating string: no filter named 'failed'. String: {% if result | failed or result.stdout | regex_replace('.(\\d+\\.\\d+\\.\\d+).', '\\1') | version_compare(docker_version_min, '<') %} True {% else %} False {% endif %}"}

我查找资料发现它要求docker版本>=2.4.6,而我现在docker的版本是1.12.6。所以我先升级docker

关于docker升级可以参考这篇博客:https://blog.csdn.net/lyc0424/article/details/107774068

但是还是没有解决问题。

然后发现在ansible2.9版本中已经移除了 使用以前允许使用带有过滤器语法的测试。 它已在ansible 2.5中被弃用(带有警告),在ansible 2.9中被完全删除。

Using tests with the filter syntax used to be allowed. It has been deprecated in ansible 2.5 (with warnings) and totally removed in ansible 2.9.

最后我参考另一位大佬的意见安装了ansible2.5.6版本。

sudo -H pip install ansible==2.5.6

 由于之前安装了最新版的ansible,后面又安装了ansible2.5.6版本,之前的ansible没卸干净,可能汇报下面的错误

from ansible import context ImportError: cannot import name context

参考这篇博客https://blog.csdn.net/lyc0424/article/details/107774234解决就行了。

参考:https://stackoverflow.com/questions/59832284/kolla-ansible-openstack-docker-version-failure

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值