How to add PHP 5.6for CyberPanel Ubuntu

How do I add PHP 5.6 as an available PHP version to use in CyberPanel?

Yes, I know it is no longer supported. I just require it for some websites that need it available during migration to new software.

Use CentOS to install CyberPanel. CentOS have PHP 5.6.

I’m running on Ubuntu 18.04, If I install PHP 5.6 on Ubuntu, do I need to install it before CyberPanel, or will it discover it if I install it after ?

ubuntu 18 doesn’t support php56 anymore as due to some openssl upgraded to newer version and among other thing.

most important of all , php56 is at EOL , comes with more security concern

I have php56 running on Ubuntu 18.04 by using a PPA. My question still stands, how does CyberPanel discover available PHP versions, and does it work to install a new version of PHP after CyberPanel?

Regarding EOL, yes, it may not be a good idea to run it in production. But that doesn’t mean someone may still need an EOL version to, for example, migrate to a newer version of some application.

I think the issue is that there isn’t an lsphp56 available to install on ubuntu 18.04. The only PPA I’m aware of for PHP 5.6 is an Apache dependent distribution.

@mericson as @sageacy said LSPPHP 5.6 is not available on Ubuntu, normally PHP might be available to install but it is not useable with LSAPI.

So doing this will be a painful and long process, the easy way is to just use CentOS 7 if PHP 5.6 is required.

However, this is how CyberPanel load PHP versions cyberpanel/phpManager.py at b990d1332fbe3491228c6f9cb15224ecee308503 · usmannasir/cyberpanel · GitHub

Even if you hack around this code, you need to set up PHP 5.6 with LiteSpeed API : PHP: LiteSpeed Web Server/OpenLiteSpeed Web Server on Unix systems - Manual

I am also in need to run PHP 5.6 on an old private website. I know it’s a horrible hack but it’s probably possible to compile it and put it under lsphp70 (provided you’re not planning on using PHP 7.0 for anything else).

Turns out my old website works fine with lsphp74 even though I wasn’t able to make it work with PHP 7 at Cloudways.

Type your comment> @therealgilles said:

I am also in need to run PHP 5.6 on an old private website. I know it’s a horrible hack but it’s probably possible to compile it and put it under lsphp70 (provided you’re not planning on using PHP 7.0 for anything else).

You have anything solution??