Play! Framework をProduction Modeで動かす


conf/application.conf に、↓を追加。%が必要です。

# 中略

↓こんなふうにして実行。下から二行目、ProdとなっていればProduction Modeです。
# pwd

# play -Dconf=conf/application.conf start
[info] Loading project definition from /var/www/html/myFirstApp/project
[info] Set current project to myFirstApp (in build file:/var/www/html/myFirstApp/)

(Starting server. Type Ctrl+D to exit logs, the server will remain in background)

Play server process ID is 10007
[info] play - Application started (Prod)
[info] play - Listening for HTTP on port 9000...

止めるときは、Ctrl + Dしてからplay stopです。