Verified Commit fea62c97 authored by Julien Gomes Dias's avatar Julien Gomes Dias
Browse files

Merge branch 'nextcloud_correction'

parents 4d71d212 3527ed8e
......@@ -71,7 +71,7 @@
name: "{{ app_instance_root }}/cron.php >/dev/null 2>&1"
user: "www-data"
minute: "*/15"
job: "php -f {{ app_instance_root }}/cron.php >/dev/null 2>&1"
job: "php{{ php_version }} -f {{ app_instance_root }}/cron.php >/dev/null 2>&1"
- name: "test absence of config.php (determines first install)"
stat:
......
......@@ -7,7 +7,7 @@
weekday: "1"
hour: "4"
minute: "0"
job: "php -f {{ app_instance_root }}/occ app:update --all >/dev/null 2>&1"
job: "php{{ php_version }} -f {{ app_instance_root }}/occ app:update --all >/dev/null 2>&1"
- name: "template for maintenance script"
template:
......
......@@ -121,3 +121,9 @@
become_user: "www-data"
vars:
ansible_ssh_pipelining: true
- name: "add missing indices in database"
command: "php{{ php_version }} {{ www_root }}/{{ app_instance_id }}/occ db:add-missing-indices"
become_user: "www-data"
vars:
ansible_ssh_pipelining: true
\ No newline at end of file
......@@ -4,4 +4,11 @@ php_memory: "512M"
php_pm_max_children: "7"
php_pm_start_servers: "2"
php_pm_min_spare_servers: "1"
php_pm_max_spare_servers: "3"
\ No newline at end of file
php_pm_max_spare_servers: "3"
opcache_max_accelerated_files: "10000"
opcache_interned_strings_buffer: "16"
opcache_save_comments: "1"
opcache_revalidate_freq: "60"
composer_version: 2.3.8
composer_sum: "c6ab768ad3239c4d4cc4f39f8ff7462925e088cd441e5bdb749fbf6efe049769"
upload_max_filesize: "2M"
......@@ -2,18 +2,11 @@
#
# thanks to https://www.devopsaurus.com/install-composer-with-ansible/
#
- name: Validate Composer checksum
- name: Download and install Composer
get_url:
checksum: "sha384:906a84df04cea2aa72f40b5f787e49f22d4c2f19492ac310e8cba5b96ac8b64115ac402c8cd292b8a03482574915d1a8"
checksum: "sha256:{{ composer_sum }}"
dest: /usr/src/
url: https://getcomposer.org/installer
- name: Download and install Composer
shell: curl -sS https://getcomposer.org/installer | php
args:
chdir: /usr/src/
creates: /usr/local/bin/composer
warn: false
url: https://getcomposer.org/download/{{ composer_version }}/composer.phar
- name: Add Composer to global path
copy:
......
......@@ -10,6 +10,56 @@
tags:
- confphpfpm
- name: "opcache.save_comments to {{ opcache_save_comments }} for PHP{{ php_version }}"
lineinfile:
line: "opcache.save_comments = {{ opcache_save_comments }}"
regexp: "^opcache.save_comments"
path: "{{ php_ini_file }}"
state: present
notify: reload php-fpm php7_fpm
tags:
- confphpfpm
- name: "opcache.revalidate_freq to {{ opcache_revalidate_freq }} for PHP{{ php_version }}"
lineinfile:
line: "opcache.revalidate_freq = {{ opcache_revalidate_freq }}"
regexp: "^opcache.revalidate_freq"
path: "{{ php_ini_file }}"
state: present
notify: reload php-fpm php7_fpm
tags:
- confphpfpm
- name: "opcache.max_accelerated_files to {{ opcache_max_accelerated_files }} for PHP{{ php_version }}"
lineinfile:
line: "opcache.max_accelerated_files = {{ opcache_max_accelerated_files }}"
regexp: "^opcache.max_accelerated_files"
path: "{{ php_ini_file }}"
state: present
notify: reload php-fpm php7_fpm
tags:
- confphpfpm
- name: "opcache.interned_strings_buffer to {{ opcache_interned_strings_buffer }} for PHP{{ php_version }}"
lineinfile:
line: "opcache.interned_strings_buffer = {{ opcache_interned_strings_buffer }}"
regexp: "^opcache.max_accelerated_files"
path: "{{ php_ini_file }}"
state: present
notify: reload php-fpm php7_fpm
tags:
- confphpfpm
- name: "upload_max_filesize to {{ upload_max_filesize }} for PHP{{ php_version }}"
lineinfile:
line: "upload_max_filesize = {{ upload_max_filesize }}"
regexp: "^upload_max_filesize"
path: "{{ php_ini_file }}"
state: present
notify: reload php-fpm php7_fpm
tags:
- confphpfpm
- name: "max children pm.max_children {{ php_pm_max_children }} for PHP{{ php_version }}"
lineinfile:
line: "pm.max_children = {{ php_pm_max_children }}"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment