Fix to make the --host argument work again.

This commit is contained in:
conradlink
2016-09-21 08:43:07 -04:00
parent 2ca20af502
commit 98914269b7

View File

@@ -3,12 +3,14 @@ import org.eclipse.jetty.webapp.WebAppContext;
import java.io.File;
import java.net.URL;
import java.net.InetSocketAddress;
import java.security.ProtectionDomain;
public class JettyLauncher {
public static void main(String[] args) throws Exception {
String host = null;
int port = 8080;
InetSocketAddress address = null;
String contextPath = "/";
boolean forceHttps = false;
@@ -29,7 +31,13 @@ public class JettyLauncher {
}
}
Server server = new Server(port);
if(host != null) {
address = new InetSocketAddress(host, port);
} else {
address = new InetSocketAddress(port);
}
Server server = new Server(address);
// SelectChannelConnector connector = new SelectChannelConnector();
// if(host != null) {