salt-stack - Saltstack 模块不可用
问题描述
尝试运行 sls 但盐告诉我该功能不可用
我的sls 必须创建一个 mongodump 文件
create-dump:
module.run:
- name: docker.run
- m_name: mongo
- cmd: 'mongodump --out=/Mongodump
当我运行 salt minion state.sls sls 时,我看到:
ID: create-dump
Function: module.run
Name: docker.run
Result: False
Comment: Module function docker.run is not available
Started: 06:03:40.273781
Duration: 728.234 ms
Changes:
--版本
Salt Version:
Salt: 3000
Dependency Versions:
cffi: 1.9.1
cherrypy: 3.5.0
dateutil: 2.5.3
docker-py: 4.3.1
gitdb: 2.0.0
gitpython: 2.1.1
Jinja2: 2.8
libgit2: 0.24.5
M2Crypto: Not Installed
Mako: 1.0.6
msgpack-pure: Not Installed
msgpack-python: 0.4.8
mysql-python: 1.3.7
pycparser: 2.17
pycrypto: 2.6.1
pycryptodome: Not Installed
pygit2: 0.24.2
Python: 3.5.3 (default, Jul 9 2020, 13:00:10)
python-gnupg: 0.3.9
PyYAML: 3.12
PyZMQ: 16.0.2
smmap: 2.0.1
timelib: Not Installed
Tornado: 4.5.3
ZMQ: 4.2.1
System Versions:
dist: debian 9.6
locale: UTF-8
machine: x86_64
release: 4.9.0-8-amd64
system: Linux
version: debian 9.6
试过 pip3 卸载 docker - 不工作
如果我重新启动服务器 docker-py 降级到 1.10.6 版本
解决方案
确保python-docker
已安装在 minion 上。
推荐阅读
- perl - 如果我想获得命令的输出,如何修复错误“命令行太长”?
- vba - 访问 VBA 抛出“运行时错误 7 - 内存不足”
- javascript - 返回 jQuery 元素的函数返回未定义
- django - 无法模拟遍历 for 循环的 django 查询对象
- macos - 如何在 Xamarin.Mac 中的应用程序级别捕获按键事件
- angular - Angular - PrimeNg - 文件上传 - PDF 文件未在 AWS S3 存储桶中正确上传
- nativescript - 如何在 NativeScript 中调试/显示所有网络请求?
- python - 有什么方法可以测试并给出真/假语句以查看文件是否存在,Python
- unity3d - 玩家的跳跃限制
- java - 如何提取我的 simplejson 数组的数据?