2017-07-03 18:22:24 +02:00
|
|
|
---
|
|
|
|
|
2017-09-06 15:34:11 +02:00
|
|
|
- name: "Set custom values for PHP config (jessie)"
|
2017-07-03 18:22:24 +02:00
|
|
|
ini_file:
|
2017-09-06 15:34:11 +02:00
|
|
|
dest: /etc/php5/apache2/conf.d/zzz-evolinux-custom.ini
|
2017-07-03 18:22:24 +02:00
|
|
|
section: PHP
|
|
|
|
option: "disable_functions"
|
|
|
|
value: "shell-exec,system,passthru,putenv,popen"
|
2017-10-10 00:03:22 +02:00
|
|
|
notify: reload apache2
|
2019-06-18 17:35:28 +02:00
|
|
|
when: ansible_lsb.codename == "jessie"
|
2017-07-03 18:22:24 +02:00
|
|
|
|
2017-09-06 15:34:11 +02:00
|
|
|
- name: "Set custom values for PHP config (Debian 9 or later)"
|
2017-07-13 14:09:24 +02:00
|
|
|
ini_file:
|
2017-09-06 15:34:11 +02:00
|
|
|
dest: /etc/php/7.0/apache2/conf.d/zzz-evolinux-custom.ini
|
2017-07-13 14:09:24 +02:00
|
|
|
section: PHP
|
|
|
|
option: "disable_functions"
|
|
|
|
value: "shell-exec,system,passthru,putenv,popen"
|
2017-10-10 00:03:22 +02:00
|
|
|
notify: reload apache2
|
2017-08-18 03:31:46 +02:00
|
|
|
when: ansible_distribution_major_version | version_compare('9', '>=')
|
2017-07-03 18:22:24 +02:00
|
|
|
|
|
|
|
- name: Install evoadmin VHost
|
|
|
|
template:
|
|
|
|
src: evoadmin.conf.j2
|
|
|
|
dest: /etc/apache2/sites-available/evoadmin.conf
|
|
|
|
notify: reload apache2
|
|
|
|
|
|
|
|
- name: Enable evoadmin vhost
|
|
|
|
command: "a2ensite evoadmin.conf"
|
|
|
|
register: cmd_a2ensite
|
|
|
|
changed_when: "'Enabling site' in cmd_a2ensite.stdout"
|
|
|
|
notify: reload apache2
|
2017-07-03 18:23:39 +02:00
|
|
|
when: evoadmin_enable_vhost
|
|
|
|
|
|
|
|
- name: Disable evoadmin vhost
|
|
|
|
command: "a2dissite evoadmin.conf"
|
|
|
|
register: cmd_a2dissite
|
|
|
|
changed_when: "'Disabling site' in cmd_a2dissite.stdout"
|
|
|
|
notify: reload apache2
|
|
|
|
when: not evoadmin_enable_vhost
|
2017-07-03 18:22:24 +02:00
|
|
|
|
|
|
|
- name: Copy config file for evoadmin
|
2017-07-03 18:23:39 +02:00
|
|
|
template:
|
|
|
|
src: config.local.php.j2
|
|
|
|
dest: "{{ evoadmin_document_root}}/conf/config.local.php"
|
2017-12-15 14:48:32 +01:00
|
|
|
mode: "0640"
|
2017-08-30 04:06:46 +02:00
|
|
|
owner: evoadmin
|
|
|
|
group: evoadmin
|
2017-07-03 18:23:39 +02:00
|
|
|
force: no
|