无法从rubdeck GUI运行Ansible命令 [英] Ansible commands are not run from rubdeck GUI

查看:73
本文介绍了无法从rubdeck GUI运行Ansible命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经用以下提到的链接步骤配置了rundeck项目. https://stackoverflow.com/questions/60011639/rundeck-integration-with-ansible-through-plugin/60019714?noredirect=1#comment106258813_60019714 我也可以在远程服务器上执行像 ls -la,df-h 这样的shell命令,但是当我使用 ansible -m ping all 时,它给出了错误(您可以请参见截图) https://imgur.com/a/ZvJjn2Z .如何解决此问题.

I have configured rundeck project with the below mentions link steps. https://stackoverflow.com/questions/60011639/rundeck-integration-with-ansible-through-plugin/60019714?noredirect=1#comment106258813_60019714 I am able to execute the shell commands like ls -la, df- h on remote server as well but when I use ansible -m ping all its gives error (you can see in the screenshot) https://imgur.com/a/ZvJjn2Z .how I can solve the issue.

推荐答案

基本上,您正在做的是在所有节点上调用ansible,并且并非所有节点都安装了Ansible,请记住,Ansible是通过Rundeck安装在服务器中的(不在所有节点,都是"ansible:找不到命令"消息的原因.

Basically what you are doing is calling ansible on all nodes and not all have Ansible installed, keep in mind that Ansible is installed in your server with Rundeck (not in all nodes, is the reason of "ansible: command not found" message).

如果您遵循了,现在您的所有命令都使用Ansible进行了包装",则无需调用直接作为命令使用Ansible(请检查步骤4和5).

If you followed this, now all your commands run "wrapped" with Ansible, you don't need to call Ansible directly as a command (check the steps 4 and 5).

现在,关于作业,只需配置一个新项目和您的节点(出现在此处)即可.现在,您可以将内置剧本添加为步骤,或将外部剧本调用到Rundeck/Ansible节点.您可以通过在作业中添加一个步骤来完成此操作,因为您可以在此处看到.

Now, about the jobs, just configure a new project and your nodes as it appears here. And now you can add inline-playbooks as step or call external playbooks to Rundeck / Ansible nodes. You can do this by adding a step to your Job as you can see here.

这篇关于无法从rubdeck GUI运行Ansible命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆