webapp/nextlcloud: Reorganize tasks files
- Apache : Split system/vhost stuff - MySQL : Rename task file to follow same convention as apache
This commit is contained in:
parent
d5e34d0a77
commit
5c7a7fe768
30
webapps/nextcloud/tasks/apache-system.yml
Normal file
30
webapps/nextcloud/tasks/apache-system.yml
Normal file
|
@ -0,0 +1,30 @@
|
|||
---
|
||||
|
||||
- name: Enable apache2 php configuration
|
||||
copy:
|
||||
src: "zzz-apache2-evolinux-custom.ini"
|
||||
dest: "/etc/php/7.4/apache2/conf.d/zzz-evolinux-custom.ini"
|
||||
mode: "0644"
|
||||
owner: root
|
||||
group: root
|
||||
force: yes
|
||||
notify: reload apache
|
||||
tags:
|
||||
- nextcloud
|
||||
|
||||
- name: Enable cli php configuration
|
||||
copy:
|
||||
src: "zzz-cli-evolinux-custom.ini"
|
||||
dest: "/etc/php/7.4/cli/conf.d/zzz-evolinux-custom.ini"
|
||||
mode: "0644"
|
||||
owner: root
|
||||
group: root
|
||||
force: yes
|
||||
notify: reload apache
|
||||
tags:
|
||||
- nextcloud
|
||||
|
||||
# - name: Generate ssl config
|
||||
# shell:
|
||||
# cmd: "/usr/local/sbin/vhost-domains {{ nextcloud_instance_name }} | /usr/local/sbin/make-csr {{ nextcloud_instance_name }}"
|
||||
# creates: "/etc/nginx/ssl/{{ nextcloud_instance_name }}.conf"
|
23
webapps/nextcloud/tasks/apache-vhost.yml
Normal file
23
webapps/nextcloud/tasks/apache-vhost.yml
Normal file
|
@ -0,0 +1,23 @@
|
|||
---
|
||||
- name: Copy Apache vhost
|
||||
template:
|
||||
src: apache-vhost.conf.j2
|
||||
dest: "/etc/apache2/sites-available/{{ nextcloud_instance_name }}.conf"
|
||||
mode: "0640"
|
||||
notify: reload apache
|
||||
tags:
|
||||
- nextcloud
|
||||
|
||||
- name: Enable Apache vhost
|
||||
file:
|
||||
src: "/etc/apache2/sites-available/{{ nextcloud_instance_name }}.conf"
|
||||
dest: "/etc/apache2/sites-enabled/{{ nextcloud_instance_name }}.conf"
|
||||
state: link
|
||||
notify: reload apache
|
||||
tags:
|
||||
- nextcloud
|
||||
|
||||
# - name: Generate ssl config
|
||||
# shell:
|
||||
# cmd: "/usr/local/sbin/vhost-domains {{ nextcloud_instance_name }} | /usr/local/sbin/make-csr {{ nextcloud_instance_name }}"
|
||||
# creates: "/etc/nginx/ssl/{{ nextcloud_instance_name }}.conf"
|
|
@ -21,7 +21,7 @@
|
|||
tags:
|
||||
- nextcloud
|
||||
|
||||
# dependency for mysql_user and mysql_db
|
||||
# dependency for mysql_user and mysql_db - python2
|
||||
- name: python modules is installed (Ansible dependency)
|
||||
apt:
|
||||
name:
|
||||
|
@ -32,7 +32,7 @@
|
|||
- nextcloud
|
||||
when: ansible_python_version is version('3', '<')
|
||||
|
||||
# dependency for mysql_user and mysql_db
|
||||
# dependency for mysql_user and mysql_db - python3
|
||||
- name: python3 modules is installed (Ansible dependency)
|
||||
apt:
|
||||
name:
|
||||
|
@ -43,12 +43,14 @@
|
|||
- nextcloud
|
||||
when: ansible_python_version is version('3', '>=')
|
||||
|
||||
- include: apache-system.yml
|
||||
|
||||
- include: user.yml
|
||||
|
||||
- include: archive.yml
|
||||
|
||||
- include: vhost-apache.yml
|
||||
- include: apache-vhost.yml
|
||||
|
||||
- include: mysql.yml
|
||||
- include: mysql-user.yml
|
||||
|
||||
- include: config.yml
|
||||
|
|
|
@ -1,48 +0,0 @@
|
|||
---
|
||||
- block:
|
||||
- name: Copy Apache vhost
|
||||
template:
|
||||
src: apache.conf.j2
|
||||
dest: "/etc/apache2/sites-available/{{ nextcloud_instance_name }}.conf"
|
||||
mode: "0640"
|
||||
notify: reload apache
|
||||
tags:
|
||||
- nextcloud
|
||||
|
||||
- name: Enable Apache vhost
|
||||
file:
|
||||
src: "/etc/apache2/sites-available/{{ nextcloud_instance_name }}.conf"
|
||||
dest: "/etc/apache2/sites-enabled/{{ nextcloud_instance_name }}.conf"
|
||||
state: link
|
||||
notify: reload apache
|
||||
tags:
|
||||
- nextcloud
|
||||
|
||||
- name: Enable apache2 php configuration
|
||||
copy:
|
||||
src: "zzz-apache2-evolinux-custom.ini"
|
||||
dest: "/etc/php/7.4/apache2/conf.d/zzz-evolinux-custom.ini"
|
||||
mode: "0644"
|
||||
owner: root
|
||||
group: root
|
||||
force: yes
|
||||
notify: reload apache
|
||||
tags:
|
||||
- nextcloud
|
||||
|
||||
- name: Enable cli php configuration
|
||||
copy:
|
||||
src: "zzz-cli-evolinux-custom.ini"
|
||||
dest: "/etc/php/7.4/cli/conf.d/zzz-evolinux-custom.ini"
|
||||
mode: "0644"
|
||||
owner: root
|
||||
group: root
|
||||
force: yes
|
||||
notify: reload apache
|
||||
tags:
|
||||
- nextcloud
|
||||
|
||||
# - name: Generate ssl config
|
||||
# shell:
|
||||
# cmd: "/usr/local/sbin/vhost-domains {{ nextcloud_instance_name }} | /usr/local/sbin/make-csr {{ nextcloud_instance_name }}"
|
||||
# creates: "/etc/nginx/ssl/{{ nextcloud_instance_name }}.conf"
|
Loading…
Reference in a new issue