I am getting the following error when run composer commands.
/opt/plesk/php/7.4/bin/php -d memory_limit=-1 /usr/lib/plesk-9.0/composer.phar update
This only appears when the command is run by a code deployment service I have setup (DeployHQ). When I run the same composer commands via the command line, SSH, the errors do not appear.
Regarding the mcrypt errors. The mycrypt module was not installed. Tried installing this, but the error persists.
Regarding the "During inheritance of..." error, I cannot replicate this anywhere. I am specifying PHP 7.4 when running the composer command. This sounds like a PHP 8 issue.
It only appears when the deployment service runs the composer commands.
One thing I noticed is that when the deployment service runs the composer commands, it downgrades "laminas/laminas-dependency-plugin" from v2.4 to 2.2. Which is correct for the Magento version I have (2.4.2), but why this downgrade does not happen when I run the composer commands I have no idea.
If anyone can shed any light on what could be the issue here, and maybe point me in the right direction.
PHP Deprecated: Return type of phpseclib_mcrypt_filter::filter($in, $out, &$consumed, $closing) should either be compatible with php_user_filter::filter($in, $out, &$consumed, bool $closing): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /var/www/vhosts/rftlve.raftfurniture.co.uk/rftstg.raftfurniture.co.uk/httpdocs/releases/20240913132334/vendor/phpseclib/mcrypt_compat/lib/mcrypt.php on line 1107PHP Deprecated: Return type of phpseclib_mcrypt_filter::onCreate() should either be compatible with php_user_filter::onCreate(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /var/www/vhosts/rftlve.raftfurniture.co.uk/rftstg.raftfurniture.co.uk/httpdocs/releases/20240913132334/vendor/phpseclib/mcrypt_compat/lib/mcrypt.php on line 1158PHP Deprecated: Return type of phpseclib_mcrypt_filter::onClose() should either be compatible with php_user_filter::onClose(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /var/www/vhosts/rftlve.raftfurniture.co.uk/rftstg.raftfurniture.co.uk/httpdocs/releases/20240913132334/vendor/phpseclib/mcrypt_compat/lib/mcrypt.php on line 1221PHP Fatal error: During inheritance of SplDoublyLinkedList: Uncaught Exception: Deprecated Functionality: Return type of Laminas\Di\DefinitionList::push($definition) should either be compatible with SplDoublyLinkedList::push(mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /var/www/vhosts/rftlve.raftfurniture.co.uk/rftstg.raftfurniture.co.uk/httpdocs/releases/20240913132334/vendor/laminas/laminas-di/src/DefinitionList.php on line 71 in /var/www/vhosts/rftlve.raftfurniture.co.uk/rftstg.raftfurniture.co.uk/httpdocs/releases/20240913132334/vendor/magento/framework/App/ErrorHandler.php:61