ansible安装httpd

时间:2023-03-08 18:02:47

---
 - hosts: web
   tasks:
       - name: "INSTALL"
         yum: name={{ item  }} state=present
         with_items:
           - httpd
           - httpd-devel
       - name: "START"
         service: name=httpd state=started enabled=yes

ansible初次接触,自动安装httpd脚本。