2015-01-14 51 views

回答

1

Ansible本身不會讓你這樣做。但Ansible Tower(他們的商業產品)允許您執行各種與Ansible有關的任務,包括通過REST界面運行劇本等。

+0

您還可以將Ansible包裝在系統中,如Rundeck,並使用該API來觸發Ansible作業。如果有幫助的話,Rundeck是免費的;) – PhillipHolmes

0

You can see the source code here,這顯示了劇本被假定爲本地:

if not os.path.exists(playbook): 
    raise errors.AnsibleError("the playbook: %s could not be found" % playbook) 
if not (os.path.isfile(playbook) or stat.S_ISFIFO(os.stat(playbook).st_mode)): 
     raise errors.AnsibleError("the playbook: %s does not appear to be a file" % playbook) 

Here's the documentation on Python's os.path,可見是爲本地文件。

相關問題