i want run gradlew
using php. have tried using exec(), shell_exec,
or passthru
. executed commands inside php script named "build.php". tried calling script browser or curl , got error
exception in thread "main" java.lang.runtimeexception: java.io.filenotfoundexception: /var/www/.gradle/wrapper/dists/gradle-2.2.1-all/6dibv5rcnnqlfbq9klf8imrndn/gradle-2.2.1-all.zip.lck (no such file or directory)
however when called command line using php build.php
, worked well.
i need gradlew
command executed through user action browser. question: might cause error , how rid of it?
thank much.
that's because don't have folder named .gradle
in /var/www
create folder , give a+rw
permissions:
mkdir /var/www/.gradle chmod a+rw /var/www/.gradle
Comments
Post a Comment