scala - How to kill a Play Framework process? -
i closed terminal window mistake , don't know pid of running play process. how find it? or, running_pid file?
i using play 2.4.6 , running in non-production mode (activator run
).
when using dev mode (activator run
), no running_pid
file generated. process won't detach , killed when terminal closed.
by default running_pid
file written ./target/universal/stage/running_pid
(inside project's root directory) when using production mode.
so, kill process (from project directory), can:
$ kill $(cat target/universal/stage/running_pid)
you can change configuration variable pidfile.path
write file ever want, long play application has correct write permissions.
for example:
pidfile.path=/var/run/play.pid
or command line argument (for staged binary):
$ target/universal/stage/bin/myapp -dpidfile.path=/var/run/play.pid
Comments
Post a Comment