How to pass options to capifony php command

447 views Asked by At

To deploy one of my site I'm using the excelent tool called: http://capifony.org/ which is very handy, but today a composer update throws the error very similar to this: http://tech.enekochan.com/2013/12/16/fix-fatal-error-allowed-memory-size-of-x-bytes-exhausted-tried-to-allocate-x-bytes-with-composer-update/.

My question is how can I pass mentioned option (-d memory_limit=-1) to php console in capifony scripts?

1

There are 1 answers

0
Alister Bulman On BEST ANSWER

The Capifony site makes mention of how to set which PHP binary is run.

All symfony tasks (both symfony 1.x and Symfony2) run using the 
default php binary on the production server. You can change this via:

set :php_bin, "/path/to/php"

Try setting the string to "/usr/bin/env php -d memory_limit=-1". The /usr/bin/env part is a Linux tool that will search the PATH for the given program, to avoid having to 'hard-code' the full path of the program into place.