CentOS.yml 547 B

12345678910111213141516171819
  1. ---
  2. - name: Ensure Apache is installed on {{ ansible_facts['distribution'] }}
  3. dnf:
  4. name: httpd
  5. state: present
  6. when: nextcloud_websrv in ["apache", "apache2"]
  7. notify: start http
  8. - name: Set nextcloud webroot on {{ ansible_facts['distribution'] }}
  9. set_fact:
  10. nextcloud_webroot: /var/www/html/nextcloud/
  11. - name: Generate Nextcloud configuration for apache
  12. template:
  13. dest: /etc/httpd/conf.d/nextcloud.conf
  14. src: nextcloud_apache2.j2
  15. mode: 0640
  16. when: nextcloud_websrv in ["apache", "apache2"]
  17. notify: restart http