ZS 12.5 EA - Composer problem

General discussion on Zend Studio
Post Reply
lansoweb
Posts: 14
Joined: Tue Jun 01, 2010 1:47 pm

ZS 12.5 EA - Composer problem

Post by lansoweb » Fri Apr 03, 2015 1:47 pm

Hello!

I have Zend Server 8 installed and configured Zend Studio's PHP to use ZS8 php executable and configuration. But now i have a problem with composer. I configured the new PHP in the composer configuration, but when i try to update it calls:

/usr/local/zend/bin/php -n -c /usr/local/zend/etc/php.ini composer.phar update

But the -n forces php not to use the .ini, and i get:

Fatal error: Class 'Phar' not found

And if i run the command without the '-n' flag it works. Is there a way to remove the -n from the command call so the php can find it's extensions?

Regards,
Leandro Silva

mich6938
Zend Product Manager
Posts: 352
Joined: Wed Jul 16, 2014 12:32 pm

Re: ZS 12.5 EA - Composer problem

Post by mich6938 » Fri Apr 03, 2015 2:10 pm

Hi,
There is no way to remove "-n" flag, but next parameter "-c /usr/local/zend/etc/php.ini" is responsible for setting php.ini from your PHP configuration. If you are using different php.ini than "/usr/local/zend/etc/php.ini" you can configure new PHP Executable in Preferences -> PHP -> PHP Executables (with php.ini you like to use) and set this PHP as default for Composer operations (Preferences -> PHP -> Composer).

Post Reply