can send a response, cannot process body yet
This commit is contained in:
@ -68,6 +68,7 @@ add_executable(ws
|
||||
ws_cobra_to_statsd.cpp
|
||||
ws_cobra_to_sentry.cpp
|
||||
ws_snake.cpp
|
||||
ws_httpd.cpp
|
||||
ws.cpp)
|
||||
|
||||
target_link_libraries(ws ixwebsocket)
|
||||
|
@ -216,6 +216,10 @@ int main(int argc, char** argv)
|
||||
->check(CLI::ExistingPath);
|
||||
runApp->add_flag("-v", verbose, "Verbose");
|
||||
|
||||
CLI::App* httpServerApp = app.add_subcommand("httpd", "HTTP server");
|
||||
httpServerApp->add_option("--port", port, "Port");
|
||||
httpServerApp->add_option("--host", hostname, "Hostname");
|
||||
|
||||
CLI11_PARSE(app, argc, argv);
|
||||
|
||||
// pid file handling
|
||||
@ -313,6 +317,10 @@ int main(int argc, char** argv)
|
||||
redisPassword, verbose,
|
||||
appsConfigPath);
|
||||
}
|
||||
else if (app.got_subcommand("httpd"))
|
||||
{
|
||||
ret = ix::ws_httpd_main(port, hostname);
|
||||
}
|
||||
|
||||
ix::uninitNetSystem();
|
||||
return ret;
|
||||
|
Reference in New Issue
Block a user