installation.packages.yml 922 B

1234567891011121314151617181920212223242526272829
  1. ---
  2. - name: Install the selinux python module
  3. yum: name=libselinux-python state=present
  4. when: ansible_os_family == "RedHat"
  5. tags: [packages,nginx]
  6. - name: Install the epel packages
  7. yum: name=epel-release state=present
  8. when: nginx_is_el|bool
  9. tags: [packages,nginx]
  10. - name: Install the nginx packages
  11. yum: name={{ item }} state=present disablerepo='*' enablerepo={{ "nginx," if nginx_official_repo else "" }}{{ yum_epel_repo }},{{ yum_base_repo }}
  12. with_items: nginx_redhat_pkg
  13. when: nginx_is_el|bool
  14. tags: [packages,nginx]
  15. - name: Install the nginx packages
  16. yum: name={{ item }} state=present
  17. with_items: nginx_redhat_pkg
  18. when: ansible_os_family == "RedHat" and not nginx_is_el|bool
  19. tags: [packages,nginx]
  20. - name: Install the nginx packages
  21. apt: name={{ item }} state=present
  22. with_items: nginx_ubuntu_pkg
  23. environment: env
  24. when: ansible_os_family == "Debian"
  25. tags: [packages,nginx]