ansible/examples/playbook.yml
Michael DeHaan 8d57ceecf1 Factoids and push variables via setup are now available to be templated in command args
as well as template files.  PLUS, variables are now expressed in playbooks without having
to know about the setup task, which means playbooks are simpler to read now.
2012-03-05 20:09:03 -05:00

18 lines
459 B
YAML

---
- hosts: all
user: root
vars:
http_port: 80
max_clients: 200
tasks:
- include: base.yml
- name: write the apache config file using vars set above
action: template src=/srv/httpd.j2 dest=/etc/httpd.conf
notify:
- restart apache
- name: ensure apache is running
action: service name=httpd state=started
- name: pointless test action
action: command /bin/echo {{ http_port }}
handlers:
- include: handlers.yml