2018-09-29 09:54:16 +02:00
|
|
|
extern crate actix;
|
|
|
|
|
2018-10-03 13:21:21 +02:00
|
|
|
extern crate rsidm;
|
2018-11-26 07:13:22 +01:00
|
|
|
use rsidm::config::Configuration;
|
|
|
|
use rsidm::core::create_server_core;
|
2018-11-11 22:59:09 +01:00
|
|
|
|
2018-09-29 09:54:16 +02:00
|
|
|
fn main() {
|
|
|
|
// read the config (if any?)
|
2018-10-03 13:21:21 +02:00
|
|
|
// How do we make the config accesible to all threads/workers? clone it?
|
|
|
|
// Make it an Arc<Config>?
|
2018-09-29 09:54:16 +02:00
|
|
|
|
2018-11-26 07:13:22 +01:00
|
|
|
// FIXME: Pass config to the server core
|
|
|
|
let config = Configuration::new();
|
|
|
|
let sys = actix::System::new("rsidm-server");
|
2018-09-29 09:54:16 +02:00
|
|
|
|
2018-11-26 07:13:22 +01:00
|
|
|
create_server_core(config);
|
2018-09-29 09:54:16 +02:00
|
|
|
let _ = sys.run();
|
|
|
|
}
|