I am using this spring boot tutorial to study spring boot. I followed the steps explicitly, but now gradle is not working. I recall installing gradle in the CentOS 7 devbox in which this is being run. How can I get gradle to launch this sample app?
Here is the terminal log typed from the root directory of the app created using the exact steps in the tutorial listed above:
[root@localhost gs-actuator-service]# ./gradlew bootRun --stacktrace
-bash: ./gradlew: No such file or directory
[root@localhost gs-actuator-service]# ./gradlew bootRun --debug --stacktrace
-bash: ./gradlew: No such file or directory
[root@localhost gs-actuator-service]# ./gradlew bootRun
-bash: ./gradlew: No such file or directory
[root@localhost gs-actuator-service]#
I also confirmed that gradle is installed on the machine by typing the following:
[root@localhost gs-actuator-service]# gradle -v
------------------------------------------------------------
Gradle 2.10
------------------------------------------------------------
Build time: 2015-12-21 21:15:04 UTC
Build number: none
Revision: 276bdcded730f53aa8c11b479986aafa58e124a6
Groovy: 2.4.4
Ant: Apache Ant(TM) version 1.9.3 compiled on December 23 2013
JVM: 1.8.0_45 (Oracle Corporation 25.45-b02)
OS: Linux 3.10.0-327.3.1.el7.x86_64 amd64
[root@localhost gs-actuator-service]#
If you use ./gradlew
, of course it only works, when the Gradle Wrapper is included in that sample project, i.e. if the script gradlew
exists in the root directory of that project. If you want to use your local Gradle installation, execute it like that:
gradle bootRun