public class StartBrixDemo {
private static final Logger logger = LoggerFactory.getLogger(StartBrixDemo.class);
public static void main(String[] args) throws Exception {
ApplicationProperties properties = new ApplicationProperties("brix.demo");
Server server = new Server();
SocketConnector connector = new SocketConnector();
// Set some timeout options to make debugging easier.
connector.setMaxIdleTime(1000 * 60 * 60);
connector.setSoLingerTime(-1);
int port = Integer.getInteger("jetty.port", properties.getHttpPort());
connector.setPort(port);
SslSocketConnector sslConnector = new SslSocketConnector();
sslConnector.setMaxIdleTime(1000 * 60 * 60);
sslConnector.setSoLingerTime(-1);
sslConnector.setKeyPassword("password");
sslConnector.setPassword("password");
sslConnector.setKeystore("src/main/webapp/WEB-INF/keystore");
port = Integer.getInteger("jetty.sslport", properties.getHttpsPort());
sslConnector.setPort(port);
server.setConnectors(new Connector[]{connector, sslConnector});