Feature/httpd (#94)
* Stub code for http server * can send a response, cannot process body yet * write headers to the response * remove commented code * add simple test + set default http handler * tweak CI + unittest * add missing file * rewrite http::trim in a simple way * doc
This commit is contained in:
committed by
GitHub
parent
b26e9d0338
commit
f84bc53c8d
@ -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