statamic / v2-hub

Statamic 2 - Feature Requests and Bug Reports
https://statamic.com
95 stars 5 forks source link

Override updater's PHP reference #2241

Open stvnthomas opened 6 years ago

stvnthomas commented 6 years ago

Is your feature request related to a problem? Please describe. We're running a CentOS 7.4 server with Plesk control panel. CentOS ships with an ancient version of PHP (5.4) that we can't get rid of and more current versions are installed through Plesk (7.2).

The website is running on PHP 7.2 but when the Statamic control panel updater is run it incorrectly references the OS's PHP (php) instead of the website's (/opt/plesk/php/7.2/bin/php). Not sure why.

This causes the following error:

================ Error Output: ================
Loading composer repositories with package information Updating dependencies Your requirements could not be resolved to an installable set of packages. Problem 1 - This package requires php >=5.5.9 but your PHP version (5.4.16) does not satisfy that requirement.

If there were a setting where we could override the updater's php reference it'd fix the problem.

Describe alternatives you've considered CLI update works but it's not for end users.

Additional context -

Would you be willing to sponsor this feature? -

jasonvarga commented 5 years ago

This is a decent feature request, however I'd suggest you avoid upgrading on production anyway. You should upgrade locally, test everything out, and deploy the changes.