Cristian Balan

Cristian Balan

Under review

When creating a site would be good to be able to choose the PHP version too.

Currently, changing the version after we create the site causes the following process duplicates with both PHP versions:

$ ps aux | grep myuser
myuser      351526  0.0  0.4 645764 17840 ?        S    23:30   0:00 php-fpm: pool www-myuser
myuser      351527  0.0  0.4 645764 17840 ?        S    23:30   0:00 php-fpm: pool www-myuser
myuser      351764  0.0  0.4 640936 16824 ?        S    23:36   0:00 php-fpm: pool www-myuser-7.4
myuser      351765  0.0  0.4 640936 16824 ?        S    23:36   0:00 php-fpm: pool www-myuser-7.4

You can notice that the website was created at 23:30 and it defaulted on the default PHP 8.2 as set on the server. At 23:36 I've changed the site to PHP 7.4 but both process are running (in fact four processes for some reason).

Indeed the old PHP 8.2 default pool the website was created with is not being deleted upon changing to a different version:

$ ls -lah /etc/php/*/fpm/pool.d/myuser.conf
-rw-r--r-- 1 root root 19K Dec  9 23:36 /etc/php/7.4/fpm/pool.d/myuser.conf
-rw-r--r-- 1 root root 19K Dec  9 23:30 /etc/php/8.2/fpm/pool.d/myuser.conf
Cristian Balan

Cristian Balan

Item author
·
·

PS. At https://developers.ploi.io/32-sites/91-create-site, we can see that the "php_version": 7.2, is given in the example output.

I know is not documented as a given option but I've tried anyway :) to imput the PHP version in the API POST call but it is completely ignored and the new site is created with the default version as per GUI.

no votes yet

Choose PHP version when creating a site (&& GUI bug)

1 total vote
Cristian Balan
  • Dennis moved item to board Under review

    9 months ago
  • Cristian Balan moved item to project Panel Requests

    1 year ago
  • Cristian Balan created the item

    1 year ago