blondie
blondie

Reputation: 35

Cannot start service through Gradle SSH

I have a service on a Ubuntu 14.04 LTS machine that starts a Play application. When I run service serviceName start directly from the machine (sudo or not), it works.

But I'm deploying this application through Gradle. My build.gradle uses the SSH plugin. It packages the application through the Play plugin for Gradle using the dist task. Then it uploads the tar to the machine and call execute service serviceName start. My service script logs that it started but when I try to access to application, it fails or when look at what ps aux | grep serviceName gives me, there's nothing displaying.

Any idea why?

Here is the part of the build.gradle that untar and runs the service.

executeSudo "$untarCommand",ignoreError: false,pty: true
println "untar done"
execute "service serverlogapi start", ignoreError: false, pty:true
println "service started"

Upvotes: 0

Views: 406

Answers (0)

Related Questions