问题
With Play 2.2.x I could set the default port with build.sbt file i.e:
Build.sbt play.Project.playScalaSettings
play.Project.playDefaultPort := 9001
After 2.3.x upgrade play.Project.playDefaultPort
does not exists any more.
I do not want to type-Dhttp.port=9001
or run 9001
回答1:
play.PlayImport.PlayKeys.playDefaultPort := 9001
https://github.com/playframework/playframework/blob/2.3.4/framework/src/sbt-plugin/src/main/scala/PlayImport.scala#L111
来源:https://stackoverflow.com/questions/26040275/how-to-change-the-default-port-9000-in-play-2-3-x-in-build-definition