cl-selector or selectorctl to switch PHP version of /usr/bin/php AND /usr/bin/php-cgi
  1. Forums
  2. CloudLinux and Control Panels
  3. CloudLinux and In-house Control Panels
  1. Mathieu Morier
  2. Tuesday, 30 May 2017
  3.  Subscribe via email
We are using selectorctl to select the PHP version for each of our user / client on a server in command line.

But the problem is that it put php-cgi in /usr/bin/php, so some command like composer does not work since PHP is not the PHP CLI version !

We have try to change /etc/cl.selector/selector.conf

-- php 7.1 7.1.5 /opt/alt/php71/usr/bin/php-cgi
++ php 7.1 7.1.5 /opt/alt/php71/usr/bin/php

Now the PHP is the PHP-CLI version, but the /usr/bin/php-cgi bin the in client Cage is not PHP 7.1, it's still an old PHP 5.x .

How can selectorctl update / put the good BIN of php and php-cgi in the cage ?

/etc/cl.selector/selector.conf already contain

php-cgi 7.1 7.1.5 /opt/alt/php71/usr/bin/php-cgi

So I was thinking php-cgi should update to the correct version in the cage ?
Rate this post:

There are no replies made for this post yet.
Be one of the first to reply to this post!
Mathieu Morier
Submit Your Response
Upload files or images for this discussion by clicking on the upload button below. Supports gif,jpg,png,zip,rar,pdf
• Insert • Remove Upload Files (Maximum File Size: 2 MB)
To protect the site from bots and unauthorized scripts, we require that you enter the captcha codes below before posting your question.