Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Specifying the Jetty port in SBT 0.10

I need to run the embedded Jetty on port different to the default 8080, using SBT 0.10 The question was answered here for SBT 0.7 - In which file do I need to add an override for the jetty port when running a lift webapp in dev mode from sbt?. I can find no reference to do the same for SBT 0.10 I am using the Full configuration (Build.scala) for multi modules and not quick the sbt dsl.

like image 812
iandebeer Avatar asked Jun 29 '11 13:06

iandebeer


2 Answers

In SBT 0.10 Jetty support no longer goes as a part of the build tool, but rather shipped as a plugin. In order to change the port, you'll have to initialize jettyPort setting with your value:

jettyPort := 1111

Or, if you're running from the console:

set jettyPort := 1111
session save

See plugin instructions for more details.

like image 174
Vasil Remeniuk Avatar answered Oct 21 '22 12:10

Vasil Remeniuk


For sbt 0.11.2 , you specify

port in container.Configuration := 8081

in build.sbt

like image 35
fmpwizard Avatar answered Oct 21 '22 11:10

fmpwizard