fix(Tools/DBImport): Add Env var support to DBimport tool (#17019)
add env var support for dbimport
This commit is contained in:
@@ -62,6 +62,8 @@ int main(int argc, char** argv)
|
|||||||
if (!sConfigMgr->LoadAppConfigs())
|
if (!sConfigMgr->LoadAppConfigs())
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
|
std::vector<std::string> overriddenKeys = sConfigMgr->OverrideWithEnvVariablesIfAny();
|
||||||
|
|
||||||
// Init logging
|
// Init logging
|
||||||
sLog->Initialize();
|
sLog->Initialize();
|
||||||
|
|
||||||
@@ -78,6 +80,9 @@ int main(int argc, char** argv)
|
|||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
for (std::string const& key : overriddenKeys)
|
||||||
|
LOG_INFO("dbimport", "Configuration field {} was overridden with environment variable.", key);
|
||||||
|
|
||||||
OpenSSLCrypto::threadsSetup();
|
OpenSSLCrypto::threadsSetup();
|
||||||
|
|
||||||
std::shared_ptr<void> opensslHandle(nullptr, [](void*) { OpenSSLCrypto::threadsCleanup(); });
|
std::shared_ptr<void> opensslHandle(nullptr, [](void*) { OpenSSLCrypto::threadsCleanup(); });
|
||||||
|
|||||||
Reference in New Issue
Block a user