alaxli / ansible_ui

ansible web ui, more simple and better layout
331 stars 181 forks source link

How to apply my "HOSTS" file contents "ansible_ui" ? #7

Open Kisung opened 9 years ago

Kisung commented 9 years ago

my hosts file contents is like this:


localhost              ansible_connection=local

[zabbix-proxy]
t-proxy  ansible_ssh_host=10.0.0.###

[zabbix-proxy:vars]
ansible_ssh_private_key_file=~/.ssh/xxx_worker.pem
ansible_ssh_user=ubuntu

[zabbix-agent]
t-agent-01      ansible_ssh_host=10.0.0.###
t-agent-02      ansible_ssh_host=10.0.0.###
t-agent-03      ansible_ssh_host=10.0.0.###
t-agent-04      ansible_ssh_host=10.0.0.###

[zabbix-agent:vars]
ansible_ssh_private_key_file=~/.ssh/xxx_worker.pem
ansible_ssh_user=ubuntu

my ansible command result like this:

[ansible@ip-10-0-0-48 cl-test]$ ansible -i hosts -m ping all
/usr/lib64/python2.6/site-packages/Crypto/Util/number.py:57: PowmInsecureWarning: Not using mpz_powm_sec.  You should rebuild using libgmp >= 5 to avoid timing attack vulnerability.
  _warn("Not using mpz_powm_sec.  You should rebuild using libgmp >= 5 to avoid timing attack vulnerability.", PowmInsecureWarning)
localhost | success >> {
    "changed": false,
    "ping": "pong"
}

t-agent-04 | success >> {
    "changed": false,
    "ping": "pong"
}

t-agent-01 | success >> {
    "changed": false,
    "ping": "pong"
}

t-agent-02 | success >> {
    "changed": false,
    "ping": "pong"
}

t-agent-03 | success >> {
    "changed": false,
    "ping": "pong"
}

t-proxy | success >> {
    "changed": false,
    "ping": "pong"
}

How to apply my "HOSTS" file contents "ansible_ui"?

ansible-ui is installed on "ip-10-0-0-48"

alaxli commented 9 years ago

just put your hosts content in yourproject - > host manage ,it will be saved as a hosts file.

Kisung commented 9 years ago
  1. My Hosts contents put in "Host Management" like This image

2.Create YAML file image

  1. Create "Execute Job" like this image
  2. but...Execute Result is this image

my pem file put in "ansible_ui" host's image

... What should I do?