Changes

Jump to navigation Jump to search
1,189 bytes added ,  15:42, 15 November 2023
m
Line 46: Line 46:  
|php55
 
|php55
 
|personnalisation de /opt/remi/php55/root/etc/php.ini
 
|personnalisation de /opt/remi/php55/root/etc/php.ini
| rowspan="8" |si aucune propriété n'est définie, les propriétés des clés php seront utilisées
+
| rowspan=11" |si aucune propriété n'est définie, les propriétés des clés php seront utilisées
 
|-
 
|-
 
|php56
 
|php56
Line 68: Line 68:  
|php80
 
|php80
 
|personnalisation de /etc/opt/remi/php80/php.ini
 
|personnalisation de /etc/opt/remi/php80/php.ini
 +
|-
 +
|php81
 +
|personnalisation de /etc/opt/remi/php81/php.ini
 +
|-
 +
|php82
 +
|personnalisation de /etc/opt/remi/php82/php.ini
 +
|-
 +
|php83
 +
|personnalisation de /etc/opt/remi/php83/php.ini
 
|}
 
|}
 
Chaque version de php a son propre service php-fpm en cours d'exécution, l'entrée de la base de données de configuration associée est (comme indiqué dans le tableau ci-dessus) php-fpm pour php (c'est-à-dire php54), php55-php-fpm pour php55 et ainsi de suite.
 
Chaque version de php a son propre service php-fpm en cours d'exécution, l'entrée de la base de données de configuration associée est (comme indiqué dans le tableau ci-dessus) php-fpm pour php (c'est-à-dire php54), php55-php-fpm pour php55 et ainsi de suite.
Line 259: Line 268:  
Après cela, lancez les commandes suivantes :
 
Après cela, lancez les commandes suivantes :
   −
  signal-event webapps-updates
+
  signal-event webapps-update
    
Accédez maintenant à nouveau à votre page et voyez quelle est l’erreur.
 
Accédez maintenant à nouveau à votre page et voyez quelle est l’erreur.
Line 282: Line 291:  
  Aug 12 17:27:42 homer httpd: PHP Warning:  main(): open_basedir restriction in effect. File(/tmp/test.php) is not within the allowed path(s): (/home/e-smith/files/ibays/Primary/html/) in /home/e-smith/files/ibays/Primary/html/test.php on line 2
 
  Aug 12 17:27:42 homer httpd: PHP Warning:  main(): open_basedir restriction in effect. File(/tmp/test.php) is not within the allowed path(s): (/home/e-smith/files/ibays/Primary/html/) in /home/e-smith/files/ibays/Primary/html/test.php on line 2
   −
En général vous ne trouverez ce message que dans les fichiers journaux car, par défaut (cf. supra), PHP est configuré pour empêcher l'affichage de messages d'erreur aux utilisateurs finaux. Cela peut être modifié selon [[PHP#Display_Error_Messages|ce guide en anglais]].
+
En général vous ne trouverez ce message que dans les fichiers journaux car, par défaut (cf. supra), PHP est configuré pour empêcher l'affichage de messages d'erreur aux utilisateurs finaux. Cela peut être modifié selon [[PHP#Display_Error_Messages|ce tutoriel en anglais]].
    
====Modification du paramètre PHPBaseDir pour une baie d'information====
 
====Modification du paramètre PHPBaseDir pour une baie d'information====
Line 311: Line 320:  
upload_tmp_dir
 
upload_tmp_dir
   −
From SME Server V8 up to and including SME Server V9, you could sometimes have an error thrown by PHP and would then need to specify a temporary directory (e.g. upload_tmp_dir) which is not set in php.ini. see [[bugzilla:6650]] and [[bugzilla:7652]]. Many php applications need this setting, the best-known culprits are Wordpress, Roundcube, eGroupWare, and there are others. ther symptoms observed are that you can't upload contents to the PHP application.
+
From SME Server V8 up to and including SME Server V9, you could sometimes have an error thrown by PHP and would then need to specify a temporary directory (e.g. upload_tmp_dir) which is not set in php.ini. see [[bugzilla:6650]] and [[bugzilla:7652]]. Many php applications need this setting, the best-known culprits are Wordpress, Roundcube, eGroupWare, and there are others. The symptoms observed are that you can't upload contents to the PHP application.
   −
An easy resolution is to make a Custom Template to resolve this issue. see [[Uploadtmpdir]]
+
An easy resolution is to make a Custom Template to resolve this issue. See [[Uploadtmpdir]].
 +
{{Warning box|type=Attention : |cette information est obsolète et incompatible avec SME10.}}
   −
=== Advanced use of the php-fpm pools ===
+
=== Utilisation avancée des ressources php-fpm ===
   −
==== For the ibays with with php-fpm.d/ibays.conf ====
+
==== Pour les baies avec php-fpm.d/ibays.conf ====
for the ibays better option is to simply use the contrib [[Webhosting]]
+
Pour les baies, la meilleure option est simplement d'utiliser la contribution [[Webhosting]].
   −
==== For the contrib sharefolders with php-fpm.d/shares.conf ====
+
==== Pour les dossiers partagés de contributioncomportant php-fpm.d/shares.conf ====
similar to ibays
+
Similaire aux baies.
   −
==== For the contribs with php-fpm.d/www.conf ====
+
==== Pour les contributions avec php-fpm.d/www.conf ====
please read [[Building Your Contrib]]
+
Veuillez lire [[Building Your Contrib cette page en anglais]].
   −
==== For your custom needs with php-fpm.d/custom.conf ====
+
==== Pour vos besoins personalisés avec php-fpm.d/custom.conf ====
you can build your own pool to use in any place on your server, even in a subfolder of an ibay or in place of the regular ibay php-pool (property PHPCustomPool)
+
Vous pouvez construire votre propre ressource pour l'utiliser où vous voulez sur le serveur, même dans un sous-répertoire d'une baie ou à la place du php-pool normal de la baie (propriété PHPCustomPool).
   −
There are two ways in doing that
+
Il y a deux manières de faire cela :
   −
===== using db php =====
+
===== en utilisant db php =====
using the default template : /etc/e-smith/templates/etc/php-fpm.d/custom.conf , you can set your own pool doing:
+
En utilisant le modèle par défaut : /etc/e-smith/templates/etc/php-fpm.d/custom.conf, vous pouvez configurer votre propre ressource en faisant :
 
  db php set MYPOOLNAME pool Version 81 status enabled
 
  db php set MYPOOLNAME pool Version 81 status enabled
here are the accepted supplementary properties, as always missing or empty means using default.
+
Voici les propriétés supplémentaires acceptables, car si elles sont manquantes ou vides signifiera que la valeur par défaut sera utilisée.
 +
 
 
{| class="wikitable"
 
{| class="wikitable"
!property
+
!propriété
!default
+
!valeur par défaut
!values
+
!valeurs
 
!information
 
!information
 
|-
 
|-
 
|status
 
|status
 
|enabled
 
|enabled
|enabled,disabled
+
|enabled, disabled
 
|-
 
|-
 
|Version
 
|Version
 
|
 
|
 
|
 
|
|php version to use eg 80 for php 8.0
+
|version php à utiliser, par ex. 80 pour php 8.0
 
|-
 
|-
 
|MemoryLimit
 
|MemoryLimit
Line 413: Line 424:  
|enabled
 
|enabled
 
|
 
|
|will use the autoprepend file
+
|utilisera le fichier autoprepend
 
|-
 
|-
 
|MailForceSender
 
|MailForceSender
Line 420: Line 431:  
|
 
|
 
|}
 
|}
you will then need two httpd.conf custom template fragment to use your pool. You will need to change  '''MYPOOL''' to what you want
+
Vous aurez alors besoin de deux fragments de modèle personnalisé httpd.conf pour utiliser votre ressource. Vous devrez changer '''MYPOOL''' en ce que vous voudrez :
 
  mkdir -p  /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf/
 
  mkdir -p  /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf/
 
  vim /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf/98mypoolusage
 
  vim /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf/98mypoolusage
Line 438: Line 449:  
     allow from all
 
     allow from all
 
  </Directory>
 
  </Directory>
then just do signal-event webapps-update
+
Puis exécutez :
 +
signal-event webapps-update
   −
===== using a templates-custom =====
+
===== en utilisant un modèle personnalisé =====
You can write your own fragment in /etc/e-smith/templates-custom/etc/php-fpm.d/custom.conf/ e.g. /etc/e-smith/templates-custom/etc/php-fpm.d/custom.conf/15mypool
+
Vous pouvez écire votre propre fragment dans /etc/e-smith/templates-custom/etc/php-fpm.d/custom.conf/, par exemple : /etc/e-smith/templates-custom/etc/php-fpm.d/custom.conf/15mypool
   −
You will also need to write a httpd fragment similarly to what shown just above.
+
Vous pouvez aussi avoir besoin d'écrire un fragment httpd de façon similaire à ce qui a été montré au paragraphe précédant.
   −
Here is an example if you want a custom pool for your ibay, in /etc/e-smith/templates-custom/etc/php-fpm.d/ibays.conf/15MYIBAY<syntaxhighlight lang="perl">
+
Voici un exemple si vous voulez une ressource personnalisée pour votre baie, dans /etc/e-smith/templates-custom/etc/php-fpm.d/ibays.conf/15MYIBAY<syntaxhighlight lang="perl">
 
{
 
{
   Line 478: Line 490:  
</syntaxhighlight>
 
</syntaxhighlight>
   −
You have then to force the ibay to use it by doing :<syntaxhighlight lang="bash">
+
Vous devez ensuite forcer la baie à l'utiliser en faisant :
db accounts MYIBAY setprop CustomPool enabled
+
db accounts MYIBAY setprop CustomPool enabled
</syntaxhighlight>This will prevent the generation of the default ibay pool in  ibays.conf , and let you use /var/run/php-fpm/php$version-$name.sock socket from your template-custom... or from the db php using the same key as the name of the ibay.
+
Cela empêchera la génération de la ressource par défaut de la baie dans ibays.conf et vous permettra d'utiliser le socket /var/run/php-fpm/php$version-$name.sock depuis votre modèle personnalisé... ou depuis la base de données php en utilisant la même clé que le nom de la baie.
   −
===Installation of composer===
+
===Installation de Composer===
 +
https://fr.wikipedia.org/wiki/Composer_(logiciel).
   −
This is made tricky as we do not have the PHP CLI configured.
+
Ceci est rendu délicat car nous n’avons pas configuré l'interface en lignes de commande PHP.
   −
But we can install it as follows with command line arguments. This is using php74
+
Mais nous pouvons l'installer comme suit avec des arguments de ligne de commande. L'exemple suivant vaut pour php74.
   −
Download:
+
Téléchargement :
 
  php74 -d allow_url_fopen=on -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
 
  php74 -d allow_url_fopen=on -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
   −
Install:
+
Vérification du hachage :
  php74 -d allow_url_fopen=on  ./composer-setup.php  
+
php74 -r "if (hash_file('sha384', 'composer-setup.php') === 'e21205b207c3ff031906575712edab6f13eb0b361f2085f1f1237b7126d785e826a450292b6cfd1d64d92e6563bbde02') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
 +
 
 +
Installation :
 +
  php74 -d allow_url_fopen=on  ./composer-setup.php
   −
=== Bugs ===
+
=== Bogues ===
Please raise bugs under the SME-Server 10.X section in [http://bugs.contribs.org/enter_bug.cgi Bugzilla] and select the smeserver-php component or use {{BugzillaFileBug|product=SME%20Server%2010.X|component=e-smith-*%20and%20smeserver-*&20packages|title=this link}}.
+
Veuillez ouvrir les bogues dans la section SME-Server 10.X de [http://bugs.contribs.org/enter_bug.cgi Bugzilla] et sélectionner le composant smeserver-php ou utiliser {{BugzillaFileBug|product=SME%20Server%2010.X|component=e-smith-*%20and%20smeserver-*&20packages|title=ce lien}}.
   −
Below is an overview of the current issues for this package:
+
Aperçu ci-dessous des problèmes en cours pour ce paquet :
{{#bugzilla:columns=id,product,version,status,summary |sort=id|order=desc |component=smeserver-php|noresultsmessage="No open bugs found."}}
+
{{#bugzilla:columns=id,product,version,status,summary |sort=id|order=desc |component=smeserver-php|noresultsmessage="Pas trouvé de bogues ouverts."}}
 
----
 
----
    
[[Category: Howto/fr]]
 
[[Category: Howto/fr]]
 +
[[Category: Webapps/fr]]
3,054

edits

Navigation menu