Skip to content

Commit

Permalink
changed template for /etc/init/{{app_name}} This seems to fix issue s…
Browse files Browse the repository at this point in the history
…bt#357 for Ubuntu 14.04.
  • Loading branch information
flowma committed Sep 23, 2014
1 parent 7cc2e09 commit 4607b1b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,14 @@ stop on stopping ${{stop_facilities}}
respawn
respawn limit ${{retries}} ${{retryTimeout}}

pre-start script
[ -d /var/run/${{app_name}} ] || install -m 755 -o ${{daemon_user}} -g ${{daemon_user}} -d /var/run/${{app_name}}
end script

# set the working directory of the job processes
chdir ${{chdir}}

# changes to the user and group before running the job's process
setuid ${{daemon_user}}

# Start the process
script
exec ./bin/${{exec}}
exec sudo -u ${{daemon_user}} ./bin/${{exec}}
end script
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ object JavaServerAppPackaging {
private[this] def defaultFacilities(loader: ServerLoader): String = {
loader match {
case SystemV => "$remote_fs $syslog"
case Upstart => "[networking]"
case Upstart => ""
case Systemd => "network.target"
}
}
Expand Down

0 comments on commit 4607b1b

Please sign in to comment.