mirror of https://github.com/embarklabs/embark.git
make namesystem service come from a config file for future development
Signed-off-by: VoR0220 <catalanor0220@gmail.com>
This commit is contained in:
parent
6b1b849df7
commit
f5a29c7f4d
|
@ -45,6 +45,7 @@ Config.prototype.loadConfigFiles = function(options) {
|
|||
this.loadBlockchainConfigFile();
|
||||
this.loadStorageConfigFile();
|
||||
this.loadCommunicationConfigFile();
|
||||
this.loadNameSystemConfigFile();
|
||||
|
||||
this.loadContractsConfigFile();
|
||||
this.loadPipelineConfigFile();
|
||||
|
@ -61,6 +62,7 @@ Config.prototype.reloadConfig = function() {
|
|||
this.loadBlockchainConfigFile();
|
||||
this.loadStorageConfigFile();
|
||||
this.loadCommunicationConfigFile();
|
||||
this.loadNameSystemConfigFile();
|
||||
this.loadContractsConfigFile();
|
||||
this.loadPipelineConfigFile();
|
||||
this.loadContractsConfigFile();
|
||||
|
@ -205,6 +207,16 @@ Config.prototype.loadStorageConfigFile = function() {
|
|||
this.storageConfig = this._mergeConfig(configFilePath, configObject, this.env);
|
||||
};
|
||||
|
||||
Config.prototype.loadNameSystemConfigFile = function() {
|
||||
// todo: spec out names for registration in the file itself for a dev chain
|
||||
var configObject = {
|
||||
"default": {
|
||||
"available_providers": ["ens"],
|
||||
"provider": "ens"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Config.prototype.loadCommunicationConfigFile = function() {
|
||||
var configObject = {
|
||||
"default": {
|
||||
|
|
|
@ -105,6 +105,7 @@ class Engine {
|
|||
"deployment": this.deploymentService,
|
||||
"fileWatcher": this.fileWatchService,
|
||||
"webServer": this.webServerService,
|
||||
"namingSystem": this.namingSystem,
|
||||
"ipfs": this.ipfsService,
|
||||
"web3": this.web3Service,
|
||||
"libraryManager": this.libraryManagerService,
|
||||
|
|
|
@ -135,6 +135,7 @@ class Embark {
|
|||
engine.startService("pipeline");
|
||||
engine.startService("deployment");
|
||||
engine.startService("codeGenerator");
|
||||
engine.startService("namingSystem");
|
||||
// TODO: this should be just 'storage' and the storage should figure out the module
|
||||
engine.startService(engine.config.storageConfig.provider);
|
||||
|
||||
|
|
Loading…
Reference in New Issue