【发布时间】:2018-05-25 07:09:35
【问题描述】:
团队,
我在设置 salt-api 时遇到了困难。
我正在安装 ubuntu 16 和 CherryPy 3.5。这是一个开放的错误https://github.com/saltstack/salt/issues/37783。
我设法降级到 CherryPy 3.2.3。
rest_cherrypy:
port: 8000
disable_ssl: True
external_auth: pam:
saltuser:
- .*
在 salt-api 和 salt-master 重启时
curl -k http://localhost:8000
{"clients": ["local", "local_async",
> "local_batch", "local_subset", "runner", "runner_async", "ssh",
> "wheel", "wheel_async"], "return": "Welcome"}
登录或提交作业时,我得到 401 Unauthorized。
curl -sSk http://localhost:8000/login -H 'Accept: application/x-yaml' -d username=saltuser -d password=passwd -d eauth=pam
curl -vki http://localhost:8000 -H "Accept: application/x-yaml" -d client=local -d tgt='stg-ubuntu102*' -d fun='cmd.run' -d "kwarg": {"cmd": "touch /tmp/mannoj"}
有人可以在这里指导我吗?
【问题讨论】:
标签: salt-stack