• Debian 11 is approaching its end-of-life (vendor EOL date - August 31, 2026). Plesk Obsidian 18.0.80 will be the last release to support it.
    If you are running Plesk Obsidian on Debian 11, we recommend you upgrade those servers to Debian 12 using our dist-upgrade tool.
  • We plan to deprecate and remove the support for XML RPC protocol versions earlier than 1.6.9.1 in Plesk Obsidian 18.0.82. We strongly recommend that you update all existing integrations using earlier versions of the XML RPC protocol to comply with the version 1.6.9.1 specification.

Issue Magento 2 / Composer / Multiple PHP issue

WebHostingAce

Silver Pleskian
Hi,

How can I run composer in PHP 7.1.? It seems even the PHP commands runs in PHP 7.1 composer find the system PHP 5.4. How can I over come this issue?

Code:
bash-4.2$ alias php='/opt/plesk/php/7.1/bin/php'
-bash-4.2$ composer update
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - magento/product-community-edition 2.2.3 requires php 7.0.2|7.0.4|~7.0.6|~7.1.0 -> your PHP version (5.4.16) does not satisfy that requirement.
    - magento/product-community-edition 2.2.3 requires ext-intl * -> the requested PHP extension intl is missing from your system.
    - Installation request for magento/product-community-edition 2.2.3 -> satisfiable by magento/product-community-edition[2.2.3].

  To enable extensions, verify that they are enabled in your .ini files:
    - /etc/php.ini
    - /etc/php.d/00-ioncube-loader.ini
    - /etc/php.d/curl.ini
    - /etc/php.d/dom.ini
    - /etc/php.d/fileinfo.ini
    - /etc/php.d/gd.ini
    - /etc/php.d/imap.ini
    - /etc/php.d/json.ini
    - /etc/php.d/mbstring.ini
    - /etc/php.d/mysql.ini
    - /etc/php.d/mysqli.ini
    - /etc/php.d/pdo.ini
    - /etc/php.d/pdo_mysql.ini
    - /etc/php.d/pdo_sqlite.ini
    - /etc/php.d/phar.ini
    - /etc/php.d/sqlite3.ini
    - /etc/php.d/wddx.ini
    - /etc/php.d/xmlreader.ini
    - /etc/php.d/xmlwriter.ini
    - /etc/php.d/xsl.ini
    - /etc/php.d/zend_extensions_psa.ini
    - /etc/php.d/zip.ini
  You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
-bash-4.2$

Thank you.
 
Thank you @IgorG

I created a .profile file with,

alias php='/opt/plesk/php/7.1/bin/php'
alias composer='/opt/plesk/php/7.1/bin/php /usr/lib64/plesk-9.0/composer.phar'

Problem solved.
 
Back
Top