From d7aed91043062a3a9ffe3f4e4b7a258f988f0d8d Mon Sep 17 00:00:00 2001 From: Mathieu Trossevin Date: Mon, 19 Oct 2020 17:33:58 +0200 Subject: [PATCH] packweb-multiphp: Change default configuration for compatibility /var/run is now /run (and it is what is used in the .service file) Have a default directory configured as bind target so things works by default --- lxc-php/defaults/main.yml | 2 +- lxc-php/tasks/misc.yml | 4 ++-- mysql-oracle/files/evolinux-defaults.cnf | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/lxc-php/defaults/main.yml b/lxc-php/defaults/main.yml index a76e1a5b..69ef9380 100644 --- a/lxc-php/defaults/main.yml +++ b/lxc-php/defaults/main.yml @@ -8,7 +8,7 @@ php_conf_allow_url_fopen: "Off" php_conf_disable_functions: "exec,shell-exec,system,passthru,popen" # Allows accessing a local mysql database using localhost -php_conf_mysql_socket_dir: Null +php_conf_mysql_socket_dir: /mysqld php_conf_mysql_default_socket: "{{ php_conf_mysql_socket_dir }}/mysqld.sock" lxc_php_version: Null diff --git a/lxc-php/tasks/misc.yml b/lxc-php/tasks/misc.yml index 4bd5728e..3b6164d0 100644 --- a/lxc-php/tasks/misc.yml +++ b/lxc-php/tasks/misc.yml @@ -27,7 +27,7 @@ lxc_container: name: "{{ lxc_php_version }}" container_config: - - "lxc.mount.entry = /var/run/mysqld {{ php_conf_mysql_socket_dir | replace('/', '', 1) }} none bind,create=dir 0 0" + - "lxc.mount.entry = /run/mysqld {{ php_conf_mysql_socket_dir | replace('/', '', 1) }} none bind,create=dir 0 0" when: php_conf_mysql_socket_dir is string - notify: Restart container + notify: "Restart container" diff --git a/mysql-oracle/files/evolinux-defaults.cnf b/mysql-oracle/files/evolinux-defaults.cnf index 395ccac4..0b4b017b 100644 --- a/mysql-oracle/files/evolinux-defaults.cnf +++ b/mysql-oracle/files/evolinux-defaults.cnf @@ -1,6 +1,8 @@ [mysqld] ###### Connexions +# Path to socket +socket = /run/mysqld/mysqld.sock # Maximum de connexions concurrentes (defaut = 100)... provoque un "Too many connections" max_connections = 250 # Maximum de connexions en attente en cas de max_connections atteint (defaut = 50)