Cloudlinux API for setting php version?
Hi.
I am writing a script for moving some 80+ websites to a cpanel setup. It creates a customer, domain, database etc via the various API's.
But, the host uses the cloudlinux php selector for cpanel. I need to change the PHP versions for every single site I upload, and it seems like none of the functions listed in the cpanel website works or are available for it.
Does anyone have experience and know how to change the cloudlinux php version selector via any sort of API? :)
-
I doubt the host only uses the cloudlinux php versions. If the cPanel versions are present, then set the account to use the "native" ( ie server default ) PHP version selectorctl -b native -u $username And just use the cPanel ea-php versions. 0 -
Unfortunately, I don't have *root access* to the server, and doing it via logging into a customer nets me the message 'selectorctl does not work in CageFS for PHP interpreter' :). We are on a managed host, where we have access to api tokens for whm, but we don't have access to the root linux user. This is due to the supplier having an uptime and management guarantee, and them having disabled a random set of functionality. I can log in and set the php version manually in cpanel, but doing it manually for every time we are doing this is a bit harsh, especially since its so tantalizingly close :) 0 -
Nice work finding that option - you are definitely more limited without root access to the system. 0
Please sign in to leave a comment.
Comments
5 comments