Unverified Commit 40c19439 authored by kladko's avatar kladko

bug/SKALE-3751-enable-zeromq

parent de97a911
...@@ -205,9 +205,10 @@ void initAll(uint32_t _logLevel, bool _checkCert, bool _autoSign, bool _generate ...@@ -205,9 +205,10 @@ void initAll(uint32_t _logLevel, bool _checkCert, bool _autoSign, bool _generate
ZMQServer::initZMQServer(_checkCert); ZMQServer::initZMQServer(_checkCert);
SGXRegistrationServer::initRegistrationServer(_autoSign); SGXRegistrationServer::initRegistrationServer(_autoSign);
CSRManagerServer::initCSRManagerServer(); CSRManagerServer::initCSRManagerServer();
ZMQServer::initZMQServer(_checkCert);
} else { } else {
SGXWalletServer::initHttpServer(); SGXWalletServer::initHttpServer();
ZMQServer::initZMQServer(_checkCert); ZMQServer::initZMQServer(false);
} }
SGXInfoServer::initInfoServer(_logLevel, _checkCert, _autoSign, _generateTestKeys); SGXInfoServer::initInfoServer(_logLevel, _checkCert, _autoSign, _generateTestKeys);
......
...@@ -25,6 +25,8 @@ ...@@ -25,6 +25,8 @@
#include "third_party/spdlog/spdlog.h" #include "third_party/spdlog/spdlog.h"
#include "common.h"
#include "ZMQServer.h" #include "ZMQServer.h"
#include "sgxwallet_common.h" #include "sgxwallet_common.h"
...@@ -155,5 +157,11 @@ void ZMQServer::initZMQServer(bool _useClientCert) { ...@@ -155,5 +157,11 @@ void ZMQServer::initZMQServer(bool _useClientCert) {
zmqServer = new ZMQServer(); zmqServer = new ZMQServer();
static std::thread serverThread(std::bind(&ZMQServer::run, ZMQServer::zmqServer)); static std::thread serverThread(std::bind(&ZMQServer::run, ZMQServer::zmqServer));
serverThread.detach(); serverThread.detach();
if (_useClientCert) {
string rootCAPath = string(SGXDATA_FOLDER) + "cert_data/rootCA.pem";
CHECK_STATE(access(rootCAPath.c_str(), F_OK) == 0);
};
spdlog::info("Inited zmq server ..."); spdlog::info("Inited zmq server ...");
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment